This commit is contained in:
Daniel Odendahl Jr
2017-06-17 03:26:31 +00:00
parent 5bb78126a9
commit fd4e35533a
129 changed files with 322 additions and 319 deletions
+8 -8
View File
@@ -57,14 +57,7 @@ module.exports = class BanCommand extends Command {
await msg.say(`Successfully banned ${member.user.tag}.`);
if (!modlogs || !modlogs.permissionsFor(this.client.user).has('SEND_MESSAGES')) {
return msg.say('Could not log the ban to the mod logs.');
} else if (!modlogs.permissionsFor(this.client.user).has('EMBED_LINKS')) {
return modlogs.send(stripIndents`
**Member:** ${member.user.tag} (${member.id})
**Action:** Ban
**Reason:** ${reason}
**Moderator:** ${msg.author.tag}
`);
} else {
} else if (modlogs.permissionsFor(this.client.user).has('EMBED_LINKS')) {
const embed = new RichEmbed()
.setAuthor(msg.author.tag, msg.author.displayAvatarURL())
.setColor(0xFF0000)
@@ -75,6 +68,13 @@ module.exports = class BanCommand extends Command {
**Reason:** ${reason}
`);
return modlogs.send({ embed });
} else {
return modlogs.send(stripIndents`
**Member:** ${member.user.tag} (${member.id})
**Action:** Ban
**Reason:** ${reason}
**Moderator:** ${msg.author.tag}
`);
}
}
};
+8 -8
View File
@@ -54,14 +54,7 @@ module.exports = class KickCommand extends Command {
await msg.say(`Successfully kicked ${member.user.tag}.`);
if (!modlogs || !modlogs.permissionsFor(this.client.user).has('SEND_MESSAGES')) {
return msg.say('Could not log the kick to the mod logs.');
} else if (!modlogs.permissionsFor(this.client.user).has('EMBED_LINKS')) {
return modlogs.send(stripIndents`
**Member:** ${member.user.tag} (${member.id})
**Action:** Kick
**Reason:** ${reason}
**Moderator:** ${msg.author.tag}
`);
} else {
} else if (modlogs.permissionsFor(this.client.user).has('EMBED_LINKS')) {
const embed = new RichEmbed()
.setAuthor(msg.author.tag, msg.author.displayAvatarURL())
.setColor(0xFFA500)
@@ -72,6 +65,13 @@ module.exports = class KickCommand extends Command {
**Reason:** ${reason}
`);
return modlogs.send({ embed });
} else {
return modlogs.send(stripIndents`
**Member:** ${member.user.tag} (${member.id})
**Action:** Kick
**Reason:** ${reason}
**Moderator:** ${msg.author.tag}
`);
}
}
};
+1 -1
View File
@@ -7,7 +7,7 @@ module.exports = class LockdownCommand extends Command {
name: 'lockdown',
group: 'moderation',
memberName: 'lockdown',
description: 'Locks down the current channel or removes a lockdown.',
description: 'Prevents users from posting in the current channel, or removes a lockdown.',
guildOnly: true,
clientPermissions: ['ADMINISTRATOR'],
userPermissions: ['ADMINISTRATOR'],
+1 -1
View File
@@ -6,7 +6,7 @@ module.exports = class PruneCommand extends Command {
name: 'prune',
group: 'moderation',
memberName: 'prune',
description: 'Deletes messages from the current channel, up to 99.',
description: 'Deletes up to 99 messages from the current channel.',
guildOnly: true,
throttling: {
usages: 1,
+8 -8
View File
@@ -58,14 +58,7 @@ module.exports = class SoftbanCommand extends Command {
await msg.say(`Successfully softbanned ${member.user.tag}.`);
if (!modlogs || !modlogs.permissionsFor(this.client.user).has('SEND_MESSAGES')) {
return msg.say('Could not log the softban to the mod logs.');
} else if (!modlogs.permissionsFor(this.client.user).has('EMBED_LINKS')) {
return modlogs.send(stripIndents`
**Member:** ${member.user.tag} (${member.id})
**Action:** Softban
**Reason:** ${reason}
**Moderator:** ${msg.author.tag}
`);
} else {
} else if (modlogs.permissionsFor(this.client.user).has('EMBED_LINKS')) {
const embed = new RichEmbed()
.setAuthor(msg.author.tag, msg.author.displayAvatarURL())
.setColor(0xFF4500)
@@ -76,6 +69,13 @@ module.exports = class SoftbanCommand extends Command {
**Reason:** ${reason}
`);
return modlogs.send({ embed });
} else {
return modlogs.send(stripIndents`
**Member:** ${member.user.tag} (${member.id})
**Action:** Softban
**Reason:** ${reason}
**Moderator:** ${msg.author.tag}
`);
}
}
};
+9 -9
View File
@@ -48,24 +48,24 @@ module.exports = class UnbanCommand extends Command {
await msg.say(`Successfully unbanned ${member.user.tag}.`);
if (!modlogs || !modlogs.permissionsFor(this.client.user).has('SEND_MESSAGES')) {
return msg.say('Could not log the unban to the mod logs.');
} else if (!modlogs.permissionsFor(this.client.user).has('EMBED_LINKS')) {
return modlogs.send(stripIndents`
**Member:** ${member.tag} (${member.id})
**Action:** Unban
**Reason:** ${reason}
**Moderator:** ${msg.author.tag}
`);
} else {
} else if (modlogs.permissionsFor(this.client.user).has('EMBED_LINKS')) {
const embed = new RichEmbed()
.setAuthor(msg.author.tag, msg.author.displayAvatarURL())
.setColor(0x00AE86)
.setTimestamp()
.setDescription(stripIndents`
**Member:** ${member.tag} (${member.id})
**Member:** ${member.user.tag} (${member.id})
**Action:** Unban
**Reason:** ${reason}
`);
return modlogs.send({ embed });
} else {
return modlogs.send(stripIndents`
**Member:** ${member.user.tag} (${member.id})
**Action:** Unban
**Reason:** ${reason}
**Moderator:** ${msg.author.tag}
`);
}
}
};
+8 -8
View File
@@ -51,14 +51,7 @@ module.exports = class WarnCommand extends Command {
await msg.say(`Successfully warned ${member.user.tag}.`);
if (!modlogs || !modlogs.permissionsFor(this.client.user).has('SEND_MESSAGES')) {
return msg.say('Could not log the warn to the mod logs.');
} else if (!modlogs.permissionsFor(this.client.user).has('EMBED_LINKS')) {
return modlogs.send(stripIndents`
**Member:** ${member.user.tag} (${member.id})
**Action:** Warn
**Reason:** ${reason}
**Moderator:** ${msg.author.tag}
`);
} else {
} else if (modlogs.permissionsFor(this.client.user).has('EMBED_LINKS')) {
const embed = new RichEmbed()
.setAuthor(msg.author.tag, msg.author.displayAvatarURL())
.setColor(0xFFFF00)
@@ -69,6 +62,13 @@ module.exports = class WarnCommand extends Command {
**Reason:** ${reason}
`);
return modlogs.send({ embed });
} else {
return modlogs.send(stripIndents`
**Member:** ${member.user.tag} (${member.id})
**Action:** Warn
**Reason:** ${reason}
**Moderator:** ${msg.author.tag}
`);
}
}
};