@depup/ws 8.21.1-depup.0 → 8.22.0-depup.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/changes.json +1 -1
- package/lib/permessage-deflate.js +3 -1
- package/lib/websocket.js +17 -3
- package/package.json +3 -3
package/README.md
CHANGED
|
@@ -13,8 +13,8 @@ npm install @depup/ws
|
|
|
13
13
|
|
|
14
14
|
| Field | Value |
|
|
15
15
|
|-------|-------|
|
|
16
|
-
| Original | [ws](https://www.npmjs.com/package/ws) @ 8.
|
|
17
|
-
| Processed | 2026-
|
|
16
|
+
| Original | [ws](https://www.npmjs.com/package/ws) @ 8.22.0 |
|
|
17
|
+
| Processed | 2026-09-27 |
|
|
18
18
|
| Smoke test | passed |
|
|
19
19
|
| Deps updated | 0 |
|
|
20
20
|
|
package/changes.json
CHANGED
|
@@ -167,7 +167,9 @@ class PerMessageDeflate {
|
|
|
167
167
|
(typeof opts.serverMaxWindowBits === 'number' &&
|
|
168
168
|
opts.serverMaxWindowBits > params.server_max_window_bits))) ||
|
|
169
169
|
(typeof opts.clientMaxWindowBits === 'number' &&
|
|
170
|
-
|
|
170
|
+
(typeof params.client_max_window_bits === 'number'
|
|
171
|
+
? opts.clientMaxWindowBits > params.client_max_window_bits
|
|
172
|
+
: !params.client_max_window_bits))
|
|
171
173
|
) {
|
|
172
174
|
return false;
|
|
173
175
|
}
|
package/lib/websocket.js
CHANGED
|
@@ -75,11 +75,24 @@ class WebSocket extends EventEmitter {
|
|
|
75
75
|
this._redirects = 0;
|
|
76
76
|
|
|
77
77
|
if (protocols === undefined) {
|
|
78
|
-
protocols
|
|
78
|
+
if (!options || options.protocols === undefined) {
|
|
79
|
+
protocols = [];
|
|
80
|
+
} else if (Array.isArray(options.protocols)) {
|
|
81
|
+
protocols = options.protocols;
|
|
82
|
+
} else {
|
|
83
|
+
protocols = [options.protocols];
|
|
84
|
+
}
|
|
79
85
|
} else if (!Array.isArray(protocols)) {
|
|
80
86
|
if (typeof protocols === 'object' && protocols !== null) {
|
|
81
87
|
options = protocols;
|
|
82
|
-
|
|
88
|
+
|
|
89
|
+
if (options.protocols === undefined) {
|
|
90
|
+
protocols = [];
|
|
91
|
+
} else if (Array.isArray(options.protocols)) {
|
|
92
|
+
protocols = options.protocols;
|
|
93
|
+
} else {
|
|
94
|
+
protocols = [options.protocols];
|
|
95
|
+
}
|
|
83
96
|
} else {
|
|
84
97
|
protocols = [protocols];
|
|
85
98
|
}
|
|
@@ -318,7 +331,6 @@ class WebSocket extends EventEmitter {
|
|
|
318
331
|
return;
|
|
319
332
|
}
|
|
320
333
|
|
|
321
|
-
this._readyState = WebSocket.CLOSING;
|
|
322
334
|
this._sender.close(code, data, !this._isServer, (err) => {
|
|
323
335
|
//
|
|
324
336
|
// This error is handled by the `'error'` listener on the socket. We only
|
|
@@ -336,6 +348,7 @@ class WebSocket extends EventEmitter {
|
|
|
336
348
|
}
|
|
337
349
|
});
|
|
338
350
|
|
|
351
|
+
this._readyState = WebSocket.CLOSING;
|
|
339
352
|
setCloseTimer(this);
|
|
340
353
|
}
|
|
341
354
|
|
|
@@ -681,6 +694,7 @@ function initAsClient(websocket, address, protocols, options) {
|
|
|
681
694
|
socketPath: undefined,
|
|
682
695
|
hostname: undefined,
|
|
683
696
|
protocol: undefined,
|
|
697
|
+
protocols: undefined,
|
|
684
698
|
timeout: undefined,
|
|
685
699
|
method: 'GET',
|
|
686
700
|
host: undefined,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@depup/ws",
|
|
3
|
-
"version": "8.
|
|
3
|
+
"version": "8.22.0-depup.0",
|
|
4
4
|
"description": "Simple to use, blazing fast and thoroughly tested websocket client and server for Node.js (with updated dependencies)",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"ws",
|
|
@@ -83,8 +83,8 @@
|
|
|
83
83
|
"changes": {},
|
|
84
84
|
"depsUpdated": 0,
|
|
85
85
|
"originalPackage": "ws",
|
|
86
|
-
"originalVersion": "8.
|
|
87
|
-
"processedAt": "2026-
|
|
86
|
+
"originalVersion": "8.22.0",
|
|
87
|
+
"processedAt": "2026-09-27T01:06:09.117Z",
|
|
88
88
|
"smokeTest": "passed"
|
|
89
89
|
}
|
|
90
90
|
}
|