You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Haha-Yes/commands/owner/dm.js

30 lines
876 B
JavaScript

const { Command } = require('discord.js-commando');
module.exports = class dmCommand extends Command {
constructor(client) {
super(client, {
name: 'dm',
group: 'owner',
memberName: 'dm',
description: 'Dm the user id',
ownerOnly: true,
args: [
{
key: 'id',
prompt: 'Wich user would you like to dm?',
type: 'string',
},
{
key: 'text',
prompt: 'Wich user would you like to dm?',
type: 'string',
}
]
});
}
async run(message, { id, text }) {
const user = this.client.users.get(id);
user.send(`**Message from the dev**\n${text}`)
message.say('DM sent')
}
};