mirror of
https://github.com/danbulant/discord.js
synced 2026-06-19 22:51:32 +00:00
Webpack build: b74c1b70b6
This commit is contained in:
parent
d81437615e
commit
a000381170
2 changed files with 11 additions and 13 deletions
|
|
@ -11521,9 +11521,6 @@ class Client extends EventEmitter {
|
|||
for (const i of this._intervals) clearInterval(i);
|
||||
this._timeouts.clear();
|
||||
this._intervals.clear();
|
||||
this.token = null;
|
||||
this.email = null;
|
||||
this.password = null;
|
||||
return this.manager.destroy();
|
||||
}
|
||||
|
||||
|
|
@ -19141,14 +19138,15 @@ class ClientManager {
|
|||
}
|
||||
|
||||
destroy() {
|
||||
return new Promise(resolve => {
|
||||
this.client.ws.destroy();
|
||||
if (!this.client.user.bot) {
|
||||
resolve(this.client.rest.methods.logout());
|
||||
} else {
|
||||
resolve();
|
||||
}
|
||||
});
|
||||
this.client.ws.destroy();
|
||||
if (this.client.user.bot) {
|
||||
this.client.token = null;
|
||||
return Promise.resolve();
|
||||
} else {
|
||||
return this.client.rest.methods.logout().then(() => {
|
||||
this.client.token = null;
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
4
discord.indev.min.js
vendored
4
discord.indev.min.js
vendored
File diff suppressed because one or more lines are too long
Loading…
Reference in a new issue