From 86062da0bdfa924bfbaca90307a9cc36ffed48d8 Mon Sep 17 00:00:00 2001 From: Braeden Sowinski Date: Tue, 11 Oct 2022 16:06:58 -0700 Subject: [PATCH] hotfix deprecated setcolors --- commands/bank.js | 8 ++++---- commands/fine.js | 2 +- commands/money.js | 2 +- commands/settings.js | 10 +++++----- commands/wallet.js | 2 +- commands/work.js | 2 +- config/config.js | 2 +- events/interactionCreate.js | 2 +- 8 files changed, 15 insertions(+), 15 deletions(-) diff --git a/commands/bank.js b/commands/bank.js index 91cc041..c4567a9 100644 --- a/commands/bank.js +++ b/commands/bank.js @@ -246,7 +246,7 @@ module.exports = { const successEmbed = new EmbedBuilder() .setTitle('Bank Notice:') .setDescription(`Successfully deposited **$${args[0].options[0].value.toFixed(2)}**\nUse \`/bank balance\` to view your balance`) - .setColor('GREEN'); + .setColor(client.config.Colors.Green); return interaction.send({ embeds: [successEmbed] }); @@ -287,7 +287,7 @@ module.exports = { const successEmbed = new EmbedBuilder() .setTitle('Bank Notice:') .setDescription(`Successfully withdrew **$${args[0].options[0].value.toFixed(2)}**\nUse \`/bank balance\` or \`/inventory wallet\` to view your cash balance`) - .setColor('GREEN'); + .setColor(client.config.Colors.Green); return interaction.send({ embeds: [successEmbed] }); @@ -522,7 +522,7 @@ module.exports = { const successEmbed = new EmbedBuilder() .setTitle('Success') .setDescription(`Successfully gave <@${targetUserID}> $${args[0].options[1].value.toFixed(2)}`) - .setColor('GREEN'); + .setColor(client.config.Colors.Green); return interaction.send({ embeds: [successEmbed] }); @@ -594,7 +594,7 @@ module.exports = { const successEmbed = new EmbedBuilder() .setTitle('Bank Notice:') .setDescription(`Successfully transfered <@${targetUserID}> $${args[0].options[1].value.toFixed(2)}`) - .setColor('GREEN'); + .setColor(client.config.Colors.Green); return interaction.send({ embeds: [successEmbed] }); } diff --git a/commands/fine.js b/commands/fine.js index 6c654bb..0091713 100644 --- a/commands/fine.js +++ b/commands/fine.js @@ -118,7 +118,7 @@ module.exports = { const successEmbed = new EmbedBuilder() .setTitle('Bank Notice:') .setDescription(`Successfully fined <@${targetUserID}> $${args[0].options[1].value.toFixed(2)}`) - .setColor('GREEN'); + .setColor(client.config.Colors.Green); return interaction.send({ embeds: [successEmbed] }); }, diff --git a/commands/money.js b/commands/money.js index ea8a3ca..bba8d21 100644 --- a/commands/money.js +++ b/commands/money.js @@ -116,7 +116,7 @@ module.exports = { const successEmbed = new EmbedBuilder() .setDescription(`Successfully ${args[0] == 'add' ? 'added' : 'removed'} $${args[0].options[1].value.toFixed(2)} ${args[0] == 'add' ? 'to' : 'from'} <@${targetUserID}>'s balance`) - .setColor('GREEN'); + .setColor(client.config.Colors.Green); return interaction.send({ embeds: [successEmbed] }); }, diff --git a/commands/settings.js b/commands/settings.js index 4fca7e6..509ba8d 100644 --- a/commands/settings.js +++ b/commands/settings.js @@ -687,7 +687,7 @@ module.exports = { const successEmbed = new EmbedBuilder() .setDescription(`Successfully ${perform} <@&${roleId}>'s income to $${args[0].options[0].options[1].value}`) - .setColor('GREEN'); + .setColor(client.config.Colors.Green); return interaction.send({ embeds: [successEmbed] }); @@ -737,7 +737,7 @@ module.exports = { const successEmbed = new EmbedBuilder() .setDescription(`Successfully set <@&${roleId}> as commercial role.\nUsers with this role can now use business commands.`) - .setColor('GREEN'); + .setColor(client.config.Colors.Green); return interaction.send({ embeds: [successEmbed] }); @@ -779,7 +779,7 @@ module.exports = { const successEmbed = new EmbedBuilder() .setDescription(`Successfully set <@&${roleId}> as officer role.\nUsers with this role can now fine other users.`) - .setColor('GREEN'); + .setColor(client.config.Colors.Green); return interaction.send({ embeds: [successEmbed] }); @@ -821,7 +821,7 @@ module.exports = { const successEmbed = new EmbedBuilder() .setDescription(`Successfully set <@&${roleId}> as dispatcher role.\nUsers with this role can now receive 911/311 notifications.`) - .setColor('GREEN'); + .setColor(client.config.Colors.Green); return interaction.send({ embeds: [successEmbed] }); @@ -864,7 +864,7 @@ module.exports = { const successEmbed = new EmbedBuilder() .setDescription(`Successfully set <@&${roleId}> as a bot admin role.\nUsers with this role can use restricted commands.`) - .setColor('GREEN'); + .setColor(client.config.Colors.Green); return interaction.send({ embeds: [successEmbed] }); diff --git a/commands/wallet.js b/commands/wallet.js index 6e20d6e..aa8bf58 100644 --- a/commands/wallet.js +++ b/commands/wallet.js @@ -168,7 +168,7 @@ module.exports = { let successEmbed = new EmbedBuilder() .setTitle('Success') .setDescription(`Successfully set ${updateAction}\nUse \`/inventory wallet\` to view your updated ID`) - .setColor('GREEN'); + .setColor(client.config.Colors.Green); return interaction.send({ embeds: [successEmbed] }); diff --git a/commands/work.js b/commands/work.js index b9b7fd8..5e67752 100644 --- a/commands/work.js +++ b/commands/work.js @@ -33,7 +33,7 @@ module.exports = { if (!hasWorkRole) { const error = new EmbedBuilder() - .setColor('RED') + .setColor(client.config.Colors.Red) .setTitle('Missing Work!') .setDescription(`It appears you don't have any work, apply for some jobs to earn your income.`) diff --git a/config/config.js b/config/config.js index c092762..80c4c30 100644 --- a/config/config.js +++ b/config/config.js @@ -2,7 +2,7 @@ require('dotenv').config(); module.exports = { Dev: "PROD.", - Version: "12.7.3", + Version: "12.7.4", Admins: ["362791661274660874", "329371697570381824"], // Admins of the bot DefaultPrefix: "?", ServerID: "955668596745461830", diff --git a/events/interactionCreate.js b/events/interactionCreate.js index 83955a6..109e89b 100644 --- a/events/interactionCreate.js +++ b/events/interactionCreate.js @@ -218,7 +218,7 @@ module.exports = async (client, interaction) => { let successEmbed = new EmbedBuilder() .setTitle('Success') .setDescription(`Successfully gave <@${targetUserID}> ${item.name}`) - .setColor('GREEN'); + .setColor(client.config.Colors.Green); return interaction.update({ embeds: [successEmbed], components: [] }); }