forked from engineering/cloudservices
add punc
parent
43b787abc0
commit
45ec2d7af1
|
@ -18,9 +18,9 @@ export default class DeleteAccount extends Command {
|
||||||
try {
|
try {
|
||||||
if (!args[1]) return this.client.commands.get('help').run(message, [this.name]);
|
if (!args[1]) return this.client.commands.get('help').run(message, [this.name]);
|
||||||
const account = await this.client.db.Account.findOne({ $or: [{ username: args[0] }, { userID: args[0] }, { emailAddress: args[0] }] });
|
const account = await this.client.db.Account.findOne({ $or: [{ username: args[0] }, { userID: args[0] }, { emailAddress: args[0] }] });
|
||||||
if (!account) return message.channel.createMessage(`${this.client.stores.emojis.error} ***Account not found***`);
|
if (!account) return message.channel.createMessage(`${this.client.stores.emojis.error} ***Account not found.***`);
|
||||||
const { root, username, userID, emailAddress } = account;
|
const { root, username, userID, emailAddress } = account;
|
||||||
if (root) return message.channel.createMessage(`${this.client.stores.emojis.error} ***Permission denied***`);
|
if (root) return message.channel.createMessage(`${this.client.stores.emojis.error} ***Permission denied.***`);
|
||||||
|
|
||||||
const pad = (number: number, amount: number): string => '0'.repeat(amount - number.toString().length) + number;
|
const pad = (number: number, amount: number): string => '0'.repeat(amount - number.toString().length) + number;
|
||||||
const randomNumber = Math.floor(Math.random() * 9999);
|
const randomNumber = Math.floor(Math.random() * 9999);
|
||||||
|
|
Loading…
Reference in New Issue