mirror of
https://github.com/arthur-pbty/xiao.git
synced 2026-06-15 08:22:37 +02:00
Cats
This commit is contained in:
@@ -50,10 +50,14 @@ module.exports = class HackbanCommand extends Command {
|
|||||||
time: 30000
|
time: 30000
|
||||||
});
|
});
|
||||||
if (!msgs.size || !['y', 'yes'].includes(msgs.first().content.toLowerCase())) return msg.say('Aborting.');
|
if (!msgs.size || !['y', 'yes'].includes(msgs.first().content.toLowerCase())) return msg.say('Aborting.');
|
||||||
await msg.guild.ban(id, {
|
try {
|
||||||
days: 7,
|
await msg.guild.ban(id, {
|
||||||
reason: `${msg.author.tag}: ${reason}`
|
days: 7,
|
||||||
});
|
reason: `${msg.author.tag}: ${reason}`
|
||||||
|
});
|
||||||
|
} catch (err) {
|
||||||
|
return msg.say(`Could not ban the user: \`${err.message}\``);
|
||||||
|
}
|
||||||
await msg.say(`Successfully banned ${user.tag}.`);
|
await msg.say(`Successfully banned ${user.tag}.`);
|
||||||
if (!modlogs) {
|
if (!modlogs) {
|
||||||
return msg.say('Could not log the ban to the mod logs.');
|
return msg.say('Could not log the ban to the mod logs.');
|
||||||
|
|||||||
Reference in New Issue
Block a user