mirror of
https://github.com/arthur-pbty/xiao.git
synced 2026-06-05 22:01:54 +02:00
Prune Fix?
This commit is contained in:
@@ -30,9 +30,6 @@ module.exports = class PruneCommand extends Command {
|
||||
return true;
|
||||
}
|
||||
return 'Too many or two few messages to delete. Limit 1-99.';
|
||||
},
|
||||
parse: count => {
|
||||
return count + 1;
|
||||
}
|
||||
}]
|
||||
});
|
||||
@@ -48,7 +45,8 @@ module.exports = class PruneCommand extends Command {
|
||||
if (!message.channel.permissionsFor(this.client.user).hasPermission('READ_MESSAGE_HISTORY')) return message.say(':x: Error! I don\'t have the Read Message History Permission!');
|
||||
if (!message.channel.permissionsFor(this.client.user).hasPermission('MANAGE_MESSAGES')) return message.say(':x: Error! I don\'t have the Manage Messages Permission!');
|
||||
}
|
||||
const { count } = args;
|
||||
let { count } = args;
|
||||
count = count + 1;
|
||||
try {
|
||||
const messages = await message.channel.fetchMessages({
|
||||
limit: count
|
||||
|
||||
Reference in New Issue
Block a user