fix a bunch of stuff that is bad practice
This commit is contained in:
parent
fa0be297ba
commit
9e77c291cb
8 changed files with 14 additions and 14 deletions
|
@ -69,7 +69,7 @@ module.exports = class Garfield extends Command {
|
|||
.then(json => {
|
||||
const embed = new client.EmbedBuilder()
|
||||
.setTitle(`#${json.data.number}: ${json.data.name}`)
|
||||
.setColor(bot.user.hexAccentColor ?? bot.displayHexColor)
|
||||
.setColor(bot.displayHexColor)
|
||||
.setImage(json.data.image.src);
|
||||
interaction.editReply({ embeds: [embed] });
|
||||
})
|
||||
|
|
|
@ -11,7 +11,7 @@ module.exports = class Inspire extends Command {
|
|||
}
|
||||
|
||||
async run (client, interaction, data) { //eslint-disable-line no-unused-vars
|
||||
interaction.deferReply();
|
||||
await interaction.deferReply();
|
||||
fetch('http://inspirobot.me/api?generate=true', { headers: { 'User-Agent': client.config.userAgent }})
|
||||
.then(res => res.text())
|
||||
.then(body => interaction.editReply(body))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue