aboutsummaryrefslogtreecommitdiff
path: root/commands/Moderation/setLogs.js
diff options
context:
space:
mode:
authorJustin <jtsshieh@outlook.com>2019-10-30 22:28:49 -0400
committerJustin <jtsshieh@outlook.com>2019-10-30 22:28:49 -0400
commit2c3bf24f5996753df4a2d4456949fc0b636f6366 (patch)
tree27700e9b0557d23a6fb0cbd9d4058d60d725caa0 /commands/Moderation/setLogs.js
parent5d778acf2066546de30f53d4d10c92a043a44a3a (diff)
downloadPokeBot-2c3bf24f5996753df4a2d4456949fc0b636f6366.tar.gz
PokeBot-2c3bf24f5996753df4a2d4456949fc0b636f6366.tar.bz2
PokeBot-2c3bf24f5996753df4a2d4456949fc0b636f6366.zip
Added an optional checkPermission function and upgraded quick.db.
Diffstat (limited to 'commands/Moderation/setLogs.js')
-rw-r--r--commands/Moderation/setLogs.js7
1 files changed, 6 insertions, 1 deletions
diff --git a/commands/Moderation/setLogs.js b/commands/Moderation/setLogs.js
index 8ae50ea..e951c45 100644
--- a/commands/Moderation/setLogs.js
+++ b/commands/Moderation/setLogs.js
@@ -8,11 +8,16 @@
* *************************************/
exports.run = async (bot, msg, args) => {
- if (!msg.member.hasPermission('MANAGE_MESSAGES')) return msg.reply('You don\'t have permission to manage messages.');
bot.plugins.settings.setStr('logs', args[0], msg.guild.id);
msg.reply('Alright, I have set the log channel to ' + args[0]);
};
+exports.checkPermission = (bot, member) => {
+ if (!member.hasPermission('MANAGE_MESSAGES')) return 'You don\'t have permission to manage messages.';
+ return true;
+}
+
+
exports.conf = {
aliases: [],
guildOnly: true,