mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-09 16:13:31 +01:00
Fix Hyper's error and make it more useful
This commit is contained in:
@@ -265,7 +265,8 @@ class WebSocketManager extends EventEmitter {
|
||||
if (this.client.options.fetchAllMembers) {
|
||||
const promises = this.client.guilds.array().map(g => g.fetchMembers());
|
||||
Promise.all(promises).then(() => this._emitReady()).catch(e => {
|
||||
this.client.emit(Constants.Event.WARN, `Error on pre-ready guild member fetching - ${e}`);
|
||||
this.client.emit(Constants.Events.WARN, 'Error in pre-ready guild member fetching');
|
||||
this.client.emit(Constants.Events.ERROR, e);
|
||||
this._emitReady();
|
||||
});
|
||||
return;
|
||||
|
||||
@@ -190,6 +190,7 @@ exports.Events = {
|
||||
TYPING_STOP: 'typingStop',
|
||||
DISCONNECT: 'disconnect',
|
||||
RECONNECTING: 'reconnecting',
|
||||
ERROR: 'error',
|
||||
WARN: 'warn',
|
||||
DEBUG: 'debug',
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user