From 1d8bec566cb08ff5ff220f53083323fa8c3fb72e Mon Sep 17 00:00:00 2001 From: nlf Date: Wed, 8 Dec 2021 15:41:15 -0800 Subject: [PATCH] deps: minipass@3.1.6 PR-URL: https://github.com/npm/cli/pull/4144 Credit: @nlf Close: #4144 Reviewed-by: @wraithgar --- node_modules/minipass/index.js | 7 ++++++- node_modules/minipass/package.json | 2 +- package-lock.json | 14 +++++++------- package.json | 2 +- 4 files changed, 15 insertions(+), 10 deletions(-) diff --git a/node_modules/minipass/index.js b/node_modules/minipass/index.js index ae134a066d77f..1835dd9bcf512 100644 --- a/node_modules/minipass/index.js +++ b/node_modules/minipass/index.js @@ -165,7 +165,12 @@ module.exports = class Minipass extends Stream { // because we're mid-write, so that'd be bad. if (this[BUFFERLENGTH] !== 0) this[FLUSH](true) - this.emit('data', chunk) + + // if we are still flowing after flushing the buffer we can emit the + // chunk otherwise we have to buffer it. + this.flowing + ? this.emit('data', chunk) + : this[BUFFERPUSH](chunk) } else this[BUFFERPUSH](chunk) diff --git a/node_modules/minipass/package.json b/node_modules/minipass/package.json index 165fa662ab4a7..1728e5108c4c2 100644 --- a/node_modules/minipass/package.json +++ b/node_modules/minipass/package.json @@ -1,6 +1,6 @@ { "name": "minipass", - "version": "3.1.5", + "version": "3.1.6", "description": "minimal implementation of a PassThrough stream", "main": "index.js", "dependencies": { diff --git a/package-lock.json b/package-lock.json index e38318d1ca525..b1824525529b5 100644 --- a/package-lock.json +++ b/package-lock.json @@ -123,7 +123,7 @@ "libnpmteam": "^2.0.3", "libnpmversion": "^2.0.1", "make-fetch-happen": "^9.1.0", - "minipass": "^3.1.3", + "minipass": "^3.1.6", "minipass-pipeline": "^1.2.4", "mkdirp": "^1.0.4", "mkdirp-infer-owner": "^2.0.0", @@ -5074,9 +5074,9 @@ "dev": true }, "node_modules/minipass": { - "version": "3.1.5", - "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.1.5.tgz", - "integrity": "sha512-+8NzxD82XQoNKNrl1d/FSi+X8wAEWR+sbYAfIvub4Nz0d22plFG72CEVVaufV8PNf4qSslFTD8VMOxNVhHCjTw==", + "version": "3.1.6", + "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.1.6.tgz", + "integrity": "sha512-rty5kpw9/z8SX9dmxblFA6edItUmwJgMeYDZRrwlIVN27i8gysGbznJwUggw2V/FVqFSDdWy040ZPS811DYAqQ==", "inBundle": true, "dependencies": { "yallist": "^4.0.0" @@ -13819,9 +13819,9 @@ "dev": true }, "minipass": { - "version": "3.1.5", - "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.1.5.tgz", - "integrity": "sha512-+8NzxD82XQoNKNrl1d/FSi+X8wAEWR+sbYAfIvub4Nz0d22plFG72CEVVaufV8PNf4qSslFTD8VMOxNVhHCjTw==", + "version": "3.1.6", + "resolved": "https://registry.npmjs.org/minipass/-/minipass-3.1.6.tgz", + "integrity": "sha512-rty5kpw9/z8SX9dmxblFA6edItUmwJgMeYDZRrwlIVN27i8gysGbznJwUggw2V/FVqFSDdWy040ZPS811DYAqQ==", "requires": { "yallist": "^4.0.0" } diff --git a/package.json b/package.json index 6e02b7ca24a00..ab40290cd082b 100644 --- a/package.json +++ b/package.json @@ -91,7 +91,7 @@ "libnpmteam": "^2.0.3", "libnpmversion": "^2.0.1", "make-fetch-happen": "^9.1.0", - "minipass": "^3.1.3", + "minipass": "^3.1.6", "minipass-pipeline": "^1.2.4", "mkdirp": "^1.0.4", "mkdirp-infer-owner": "^2.0.0",