mirror of
https://github.com/danbulant/discord.js
synced 2026-06-19 14:41:36 +00:00
Webpack build for branch master: c5efa985fc
This commit is contained in:
parent
8478f27cd2
commit
3e0e575f36
2 changed files with 11 additions and 1 deletions
|
|
@ -17369,6 +17369,10 @@ class WebSocketConnection extends EventEmitter {
|
|||
*/
|
||||
reconnect() {
|
||||
this.debug('Attemping to reconnect in 5500ms...');
|
||||
/**
|
||||
* Emitted whenever the client tries to reconnect to the WebSocket.
|
||||
* @event Client#reconnecting
|
||||
*/
|
||||
this.client.emit(Constants.Events.RECONNECTING);
|
||||
this.connect(this.gateway, 5500, true);
|
||||
}
|
||||
|
|
@ -17399,6 +17403,12 @@ class WebSocketConnection extends EventEmitter {
|
|||
this.heartbeat(-1);
|
||||
// Should we reconnect?
|
||||
if (Constants.WSCodes[event.code]) {
|
||||
/**
|
||||
* Emitted when the client's WebSocket disconnects and will no longer attempt to reconnect.
|
||||
* @event Client#disconnect
|
||||
* @param {CloseEvent} event The WebSocket close event
|
||||
*/
|
||||
this.client.emit(Constants.Events.DISCONNECT, event);
|
||||
this.debug(Constants.WSCodes[event.code]);
|
||||
this.destroy();
|
||||
return;
|
||||
|
|
|
|||
2
discord.master.min.js
vendored
2
discord.master.min.js
vendored
File diff suppressed because one or more lines are too long
Loading…
Reference in a new issue