This commit is contained in:
Daniel Odendahl Jr
2017-05-06 17:22:47 +00:00
parent 69bdc069f0
commit 1da7be553c
3 changed files with 4 additions and 4 deletions
+2 -2
View File
@@ -26,12 +26,12 @@ module.exports = class DiscrimCommand extends Command {
});
}
async run(msg, args) {
run(msg, args) {
if(msg.channel.type !== 'dm')
if(!msg.channel.permissionsFor(this.client.user).has('EMBED_LINKS'))
return msg.say('This Command requires the `Embed Links` Permission.');
const { discrim } = args;
const users = await this.client.users.filter(u => u.discriminator === discrim).map(u => u.username).sort();
const users = this.client.users.filter(u => u.discriminator === discrim).map(u => u.username).sort();
const embed = new RichEmbed()
.setTitle(`${users.length} Users with the discriminator: ${discrim}`)
.setDescription(users.join(', '));
+1 -1
View File
@@ -27,7 +27,7 @@ module.exports = class UserInfoCommand extends Command {
});
}
async run(msg, args) {
run(msg, args) {
if(msg.channel.type !== 'dm')
if(!msg.channel.permissionsFor(this.client.user).has('EMBED_LINKS'))
return msg.say('This Command requires the `Embed Links` Permission.');
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "xiaobot",
"version": "18.3.3",
"version": "18.3.4",
"description": "A Discord Bot",
"main": "shardingmanager.js",
"scripts": {