Revert "add @discordjs/opus + jmd.js"

This reverts commit 5c2e0737c0.
This commit is contained in:
2021-04-11 12:15:40 +02:00
parent 5c2e0737c0
commit ead89a22d8
977 changed files with 1074 additions and 199471 deletions

View File

@@ -376,16 +376,12 @@ class PerMessageDeflate {
this._inflate[kTotalLength]
);
if (this._inflate._readableState.endEmitted) {
if (fin && this.params[`${endpoint}_no_context_takeover`]) {
this._inflate.close();
this._inflate = null;
} else {
this._inflate[kTotalLength] = 0;
this._inflate[kBuffers] = [];
if (fin && this.params[`${endpoint}_no_context_takeover`]) {
this._inflate.reset();
}
}
callback(null, data);
@@ -452,11 +448,12 @@ class PerMessageDeflate {
//
this._deflate[kCallback] = null;
this._deflate[kTotalLength] = 0;
this._deflate[kBuffers] = [];
if (fin && this.params[`${endpoint}_no_context_takeover`]) {
this._deflate.reset();
this._deflate.close();
this._deflate = null;
} else {
this._deflate[kTotalLength] = 0;
this._deflate[kBuffers] = [];
}
callback(null, data);

View File

@@ -225,7 +225,7 @@ class WebSocketServer extends EventEmitter {
const info = {
origin:
req.headers[`${version === 8 ? 'sec-websocket-origin' : 'origin'}`],
secure: !!(req.socket.authorized || req.socket.encrypted),
secure: !!(req.connection.authorized || req.connection.encrypted),
req
};

2
node_modules/ws/lib/websocket.js generated vendored
View File

@@ -695,7 +695,7 @@ function tlsConnect(options) {
options.path = undefined;
if (!options.servername && options.servername !== '') {
options.servername = net.isIP(options.host) ? '' : options.host;
options.servername = options.host;
}
return tls.connect(options);