diff options
author | IRONM00N <64110067+IRONM00N@users.noreply.github.com> | 2021-07-26 22:53:27 -0400 |
---|---|---|
committer | IRONM00N <64110067+IRONM00N@users.noreply.github.com> | 2021-07-26 22:53:27 -0400 |
commit | 7990abdb511eeec2a114b124a3628b10bfefc342 (patch) | |
tree | c9cc92439bb0b8385e8fcd82c169fd6f86bb1974 /src/commands/info/pronouns.ts | |
parent | 80d5b5b11ae261945dc725a0a80115922003afcf (diff) | |
download | tanzanite-7990abdb511eeec2a114b124a3628b10bfefc342.tar.gz tanzanite-7990abdb511eeec2a114b124a3628b10bfefc342.tar.bz2 tanzanite-7990abdb511eeec2a114b124a3628b10bfefc342.zip |
chore: add new eslint rule
Diffstat (limited to 'src/commands/info/pronouns.ts')
-rw-r--r-- | src/commands/info/pronouns.ts | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/commands/info/pronouns.ts b/src/commands/info/pronouns.ts index 0a5c0bc..82ee04f 100644 --- a/src/commands/info/pronouns.ts +++ b/src/commands/info/pronouns.ts @@ -60,14 +60,14 @@ export default class PronounsCommand extends BushCommand { slash: true }); } - async exec(message: Message | BushSlashMessage, args: { user?: User }): Promise<void> { + async exec(message: Message | BushSlashMessage, args: { user?: User }): Promise<unknown> { const user = args.user || message.author; const author = user.id === message.author.id; try { const apiRes: { pronouns: pronounsType } = await got .get(`https://pronoundb.org/api/v1/lookup?platform=discord&id=${user.id}`) .json(); - message.util.reply({ + return await message.util.reply({ embeds: [ new MessageEmbed({ title: `${author ? 'Your' : `${user.tag}'s`} pronouns:`, @@ -81,11 +81,11 @@ export default class PronounsCommand extends BushCommand { } catch (e) { if (e instanceof HTTPError && e.response.statusCode === 404) { if (author) { - await message.util.reply( + return await message.util.reply( 'You do not appear to have any pronouns set. Please go to https://pronoundb.org/ and set your pronouns.' ); } else { - await message.util.reply( + return await message.util.reply( `${user.tag} does not appear to have any pronouns set. Please tell them to go to https://pronoundb.org/ and set their pronouns.` ); } |