From ceaf1ee3f5200a1ce24fcd7f1da1b4433244d748 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E2=80=9C=E9=99=B6=E9=87=91=E6=B2=9B=E2=80=9D?= Date: Tue, 20 May 2025 10:46:11 +0800 Subject: [PATCH] =?UTF-8?q?ai=20alarm:=E6=B7=BB=E5=8A=A0catch=E6=96=B9?= =?UTF-8?q?=E6=B3=95=E5=A4=84=E7=90=86promise=E7=9A=84=E6=8B=92=E7=BB=9D?= =?UTF-8?q?=E7=9A=84=E6=83=85=E5=86=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: “陶金沛” --- interfaces/kits/ts/streamrw/src/streamrw.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/interfaces/kits/ts/streamrw/src/streamrw.ts b/interfaces/kits/ts/streamrw/src/streamrw.ts index d3f3e35dd..86ec05340 100644 --- a/interfaces/kits/ts/streamrw/src/streamrw.ts +++ b/interfaces/kits/ts/streamrw/src/streamrw.ts @@ -96,6 +96,9 @@ class ReadStream extends stream.Readable { this.offset = this.offset - readSize + readOut; this.push(null); } + }) + .finally(() => { + this.stream?.flush(); }); } } -- Gitee