From 678313b17677e012ba9a07aeca58af1aafbf4e8c Mon Sep 17 00:00:00 2001 From: Nayeem Rahman Date: Tue, 28 Apr 2020 17:40:43 +0100 Subject: BREAKING: Remove Deno.EOF, use null instead (#4953) --- std/archive/tar.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'std/archive') 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 { + public async read(p: Uint8Array): Promise { 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; } -- cgit v1.2.3