From 870d2007163f687b1014db4e5cb43f95aff6d77f Mon Sep 17 00:00:00 2001 From: Luca Casonato Date: Fri, 17 Jun 2022 12:49:57 +0200 Subject: [PATCH] fix(ext/web): handle rid=0 in TextDecoder#decode (#14894) --- ext/web/08_text_encoding.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/web/08_text_encoding.js b/ext/web/08_text_encoding.js index 86ac5ab3c0..282618da30 100644 --- a/ext/web/08_text_encoding.js +++ b/ext/web/08_text_encoding.js @@ -143,7 +143,7 @@ stream: options.stream, }); } finally { - if (!options.stream && this.#rid) { + if (!options.stream && this.#rid !== null) { core.close(this.#rid); this.#rid = null; }