Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
incognitojam committed Mar 6, 2025
1 parent ee6e6fb commit 755b0c8
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/sparse.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,11 +43,13 @@ export async function from(stream) {
let buffer = new Uint8Array(0);

const readUntil = async (byteLength) => {
const parts = [buffer];
while (buffer.byteLength < byteLength) {
const { value, done } = await reader.read();
if (done) throw new Error("Unexpected end of stream");

Check failure on line 49 in src/sparse.js

View workflow job for this annotation

GitHub Actions / test

error: Unexpected end of stream

at <anonymous> (/home/runner/work/qdl.js/qdl.js/src/sparse.js:49:23)

Check failure on line 49 in src/sparse.js

View workflow job for this annotation

GitHub Actions / test

error: Unexpected end of stream

at <anonymous> (/home/runner/work/qdl.js/qdl.js/src/sparse.js:49:23)
buffer = concatUint8Array([buffer, value]);
parts.push(value);
}
if (parts.length > 1) buffer = concatUint8Array(parts);
}

let header;
Expand Down

0 comments on commit 755b0c8

Please sign in to comment.