summaryrefslogtreecommitdiff
path: root/std/archive
diff options
context:
space:
mode:
Diffstat (limited to 'std/archive')
-rw-r--r--std/archive/tar.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/std/archive/tar.ts b/std/archive/tar.ts
index 28c4bbd9a..225bcb769 100644
--- a/std/archive/tar.ts
+++ b/std/archive/tar.ts
@@ -41,12 +41,12 @@ class FileReader implements Deno.Reader {
constructor(private filePath: string) {}
- public async read(p: Uint8Array): Promise<number | Deno.EOF> {
+ public async read(p: Uint8Array): Promise<number | null> {
if (!this.file) {
this.file = await Deno.open(this.filePath, { read: true });
}
const res = await Deno.read(this.file.rid, p);
- if (res === Deno.EOF) {
+ if (res === null) {
Deno.close(this.file.rid);
this.file = undefined;
}