mirror of
https://github.com/danbulant/discord.js
synced 2026-05-27 22:11:53 +00:00
fix(TextBasedChannel): bulkDelete should not return non-Promise
This commit is contained in:
parent
7ce1d1642c
commit
72346fb47e
1 changed files with 1 additions and 1 deletions
|
|
@ -454,7 +454,7 @@ class TextBasedChannel {
|
|||
if (filterOld) {
|
||||
messages = messages.filter(m => Date.now() - Snowflake.deconstruct(m.id).date.getTime() < 1209600000);
|
||||
}
|
||||
if (messages.length === 0) return new Collection();
|
||||
if (messages.length === 0) return Promise.resolve(new Collection());
|
||||
if (messages.length === 1) {
|
||||
return messages[0].delete().then(() => new Collection([[messages[0].id, messages[0]]]));
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue