diff options
Diffstat (limited to 'std/http/_io.ts')
-rw-r--r-- | std/http/_io.ts | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/std/http/_io.ts b/std/http/_io.ts index 1b6383acc..b7efaf8e5 100644 --- a/std/http/_io.ts +++ b/std/http/_io.ts @@ -69,7 +69,7 @@ export function chunkedBodyReader(h: Headers, r: BufReader): Deno.Reader { const [chunkSizeString] = line.split(";"); const chunkSize = parseInt(chunkSizeString, 16); if (Number.isNaN(chunkSize) || chunkSize < 0) { - throw new Error("Invalid chunk size"); + throw new Deno.errors.InvalidData("Invalid chunk size"); } if (chunkSize > 0) { if (chunkSize > buf.byteLength) { |