From 698262d24c7f7281cceceae11d54fdfca78e74bc Mon Sep 17 00:00:00 2001 From: Daniel Odendahl Jr Date: Fri, 31 Mar 2017 00:22:08 +0000 Subject: [PATCH] Prune Error Catch --- commands/moderation/prune.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/commands/moderation/prune.js b/commands/moderation/prune.js index 78cfa1eb..a4ad1181 100644 --- a/commands/moderation/prune.js +++ b/commands/moderation/prune.js @@ -44,10 +44,11 @@ module.exports = class PruneCommand extends commando.Command { let messages = await message.channel.fetchMessages({ limit: count }); - message.channel.bulkDelete(messages, true); + let deletion = await message.channel.bulkDelete(messages, true); + return deletion; } catch (err) { - return message.say(':x: Error! Something went wrong!'); + return message.say(':x: Error! Something went wrong! Perhaps there are not enough messages in the channel from earlier than two weeks?'); } } };