Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
testfax committed Oct 5, 2024
1 parent 5f5402f commit be209c1
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions commands/GuardianAI/promotionRequest/requestpromotion.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,15 +25,11 @@ function getPercentage(part, whole) {

module.exports = {
getRankEmoji: async function (interaction) {

let roles = await interaction.member.roles.cache.map(role=>role.name)
roles = roles.filter(x=>x != '@everyone')


const rankObj = config[botIdent().activeBot.botName].officer_ranks.find(rank =>
roles.includes(rank.rank_name)
)
console.log(rankObj)
return rankObj.emoji
},
promotionChallengeResult: async function (data,interaction) {
Expand Down Expand Up @@ -66,9 +62,7 @@ module.exports = {
// .setColor('#f2ff00') //bight yellow
.setAuthor(oldEmbedSchema.author)
.setThumbnail(botIdent().activeBot.icon)
// newEmbed.addFields(
// { name: "Promotion Status", value: "<:customEmojiName:emojiID> Promotion Approved!", inline: false }
// );

newEmbed.setColor(challenge_score_color)
let rank_emoji = await module.exports.getRankEmoji(interaction);
if (rank_emoji == null) { rank_emoji == "" }
Expand Down

0 comments on commit be209c1

Please sign in to comment.