mirror of
https://github.com/UniverseDevGroup/PokeBot.git
synced 2025-01-22 17:32:00 -05:00
linty lint
This commit is contained in:
parent
39bd1d4692
commit
2cd3309275
2 changed files with 72 additions and 74 deletions
|
@ -18,40 +18,39 @@
|
||||||
*
|
*
|
||||||
* *************************************/
|
* *************************************/
|
||||||
|
|
||||||
exports.run = async (bot, msg, args) => {
|
exports.run = async (bot, msg) => {
|
||||||
if (!msg.member.hasPermission('BAN_MEMBERS')) return msg.reply('You don\'t have permission to interrogate others. Rip-off detectives...');
|
if (!msg.member.hasPermission('BAN_MEMBERS')) return msg.reply('You don\'t have permission to interrogate others. Rip-off detectives...');
|
||||||
if (!msg.guild.member(bot.user).hasPermission('MANAGE_ROLES')) return msg.reply('I cannot interrogate anyone.');
|
if (!msg.guild.member(bot.user).hasPermission('MANAGE_ROLES')) return msg.reply('I cannot interrogate anyone.');
|
||||||
|
|
||||||
const member = msg.mentions.members.first();
|
const member = msg.mentions.members.first();
|
||||||
if (!member) return await msg.reply('Who do I interrogate?');
|
if (!member) return await msg.reply('Who do I interrogate?');
|
||||||
|
|
||||||
member.addRole(msg.guild.roles.find('name', 'Interrogation'));
|
member.addRole(msg.guild.roles.find('name', 'Interrogation'));
|
||||||
|
|
||||||
const { RichEmbed } = require('discord.js');
|
const { RichEmbed } = require('discord.js');
|
||||||
try {
|
try {
|
||||||
const embed = new RichEmbed()
|
const embed = new RichEmbed()
|
||||||
.setColor(0x00ae86)
|
.setColor(0x00ae86)
|
||||||
.setAuthor(member.user.tag, member.user.avatarURL)
|
.setAuthor(member.user.tag, member.user.avatarURL)
|
||||||
.setTitle(`Interrogation: **${member.user.tag}**`)
|
.setTitle(`Interrogation: **${member.user.tag}**`)
|
||||||
.setDescription(`*${member.user.tag}* was interrogated by *${msg.author.tag}*.`)
|
.setDescription(`*${member.user.tag}* was interrogated by *${msg.author.tag}*.`)
|
||||||
.addField('Moderator', msg.author.tag)
|
.addField('Moderator', msg.author.tag)
|
||||||
.setTimestamp()
|
.setTimestamp()
|
||||||
.setFooter(`${msg.author.tag} interrogated ${member.user.tag}.`, msg.author.avatarURL);
|
.setFooter(`${msg.author.tag} interrogated ${member.user.tag}.`, msg.author.avatarURL);
|
||||||
msg.guild.channels.find('name', 'logs').send({ embed });
|
msg.guild.channels.find('name', 'logs').send({ embed });
|
||||||
}
|
}
|
||||||
catch (err) {
|
catch (err) {
|
||||||
console.error(err.stack);
|
console.error(err.stack);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
exports.conf = {
|
exports.conf = {
|
||||||
aliases: [],
|
aliases: [],
|
||||||
guildOnly: true,
|
guildOnly: true,
|
||||||
};
|
};
|
||||||
|
|
||||||
exports.help = {
|
exports.help = {
|
||||||
name: 'interrogate',
|
name: 'interrogate',
|
||||||
description: 'Interrogate a suspect/user.',
|
description: 'Interrogate a suspect/user.',
|
||||||
usage: '@user',
|
usage: '@user',
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -18,40 +18,39 @@
|
||||||
*
|
*
|
||||||
* *************************************/
|
* *************************************/
|
||||||
|
|
||||||
exports.run = async (bot, msg, args) => {
|
exports.run = async (bot, msg) => {
|
||||||
if (!msg.member.hasPermission('BAN_MEMBERS')) return msg.reply('You don\'t have permission to put members in jail.');
|
if (!msg.member.hasPermission('BAN_MEMBERS')) return msg.reply('You don\'t have permission to put members in jail.');
|
||||||
if (!msg.guild.member(bot.user).hasPermission('MANAGE_ROLES')) return msg.reply('I cannot put anyone in jail.');
|
if (!msg.guild.member(bot.user).hasPermission('MANAGE_ROLES')) return msg.reply('I cannot put anyone in jail.');
|
||||||
|
|
||||||
const member = msg.mentions.members.first();
|
const member = msg.mentions.members.first();
|
||||||
if (!member) return await msg.reply('Who do I put in jail?');
|
if (!member) return await msg.reply('Who do I put in jail?');
|
||||||
|
|
||||||
member.addRole(msg.guild.roles.find('name', 'Jail'));
|
member.addRole(msg.guild.roles.find('name', 'Jail'));
|
||||||
|
|
||||||
const { RichEmbed } = require('discord.js');
|
const { RichEmbed } = require('discord.js');
|
||||||
try {
|
try {
|
||||||
const embed = new RichEmbed()
|
const embed = new RichEmbed()
|
||||||
.setColor(0x00ae86)
|
.setColor(0x00ae86)
|
||||||
.setAuthor(member.user.tag, member.user.avatarURL)
|
.setAuthor(member.user.tag, member.user.avatarURL)
|
||||||
.setTitle(`Jail: **${member.user.tag}**`)
|
.setTitle(`Jail: **${member.user.tag}**`)
|
||||||
.setDescription(`*${member.user.tag}* was placed in jail by *${msg.author.tag}*.`)
|
.setDescription(`*${member.user.tag}* was placed in jail by *${msg.author.tag}*.`)
|
||||||
.addField('Moderator', msg.author.tag)
|
.addField('Moderator', msg.author.tag)
|
||||||
.setTimestamp()
|
.setTimestamp()
|
||||||
.setFooter(`${msg.author.tag} put ${member.user.tag} in jail.`, msg.author.avatarURL);
|
.setFooter(`${msg.author.tag} put ${member.user.tag} in jail.`, msg.author.avatarURL);
|
||||||
msg.guild.channels.find('name', 'logs').send({ embed });
|
msg.guild.channels.find('name', 'logs').send({ embed });
|
||||||
}
|
}
|
||||||
catch (err) {
|
catch (err) {
|
||||||
console.error(err.stack);
|
console.error(err.stack);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
exports.conf = {
|
exports.conf = {
|
||||||
aliases: [],
|
aliases: [],
|
||||||
guildOnly: true,
|
guildOnly: true,
|
||||||
};
|
};
|
||||||
|
|
||||||
exports.help = {
|
exports.help = {
|
||||||
name: 'jail',
|
name: 'jail',
|
||||||
description: 'Jail a user.',
|
description: 'Jail a user.',
|
||||||
usage: '@user',
|
usage: '@user',
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue