mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-10 00:23:30 +01:00
fix(DMChannel): messages not being cached (#2122)
This commit is contained in:
@@ -69,9 +69,10 @@ class ClientDataManager {
|
||||
}
|
||||
}
|
||||
|
||||
if (channel) {
|
||||
if (this.pastReady && !already) this.client.emit(Constants.Events.CHANNEL_CREATE, channel);
|
||||
if (channel && !already) {
|
||||
if (this.pastReady) this.client.emit(Constants.Events.CHANNEL_CREATE, channel);
|
||||
this.client.channels.set(channel.id, channel);
|
||||
} else if (already) {
|
||||
return channel;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user