feat(smartjson): Add JSONL stringify and ordering comparator; fix empty buffer handling; refactor Smartjson folding/enfolding
This commit is contained in:
@@ -52,11 +52,7 @@ const replacer: TParseReplacer = (key, value) => {
|
||||
|
||||
// Handle IBufferLike objects with a .data property
|
||||
if ('data' in value && isArray(value.data)) {
|
||||
if (value.data.length > 0) {
|
||||
bufferData = new Uint8Array(value.data);
|
||||
} else {
|
||||
return ''; // Return empty string for empty data arrays
|
||||
}
|
||||
bufferData = new Uint8Array(value.data);
|
||||
}
|
||||
// Handle Uint8Array directly
|
||||
else if (value instanceof Uint8Array) {
|
||||
|
Reference in New Issue
Block a user