From 7020b7aec07b84359b156704afbf69fe4da605ea Mon Sep 17 00:00:00 2001 From: WhatCats Date: Thu, 29 Feb 2024 14:05:25 +0100 Subject: [PATCH] add prefixes to promotion messages --- src/modules/vouch-system/AutoPromoteHandler.ts | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/modules/vouch-system/AutoPromoteHandler.ts b/src/modules/vouch-system/AutoPromoteHandler.ts index 8d46ac6..bcd535c 100644 --- a/src/modules/vouch-system/AutoPromoteHandler.ts +++ b/src/modules/vouch-system/AutoPromoteHandler.ts @@ -14,6 +14,12 @@ for (const rank of Object.values(RANKS)) { Config.declareType(`${rank} Devouch Expiration`) } +const PROMOTION_PREFIX: Record = { + Prime: "### ", + Private: "## ", + Premium: "# " +} + export class AutoPromoteHandler { static onVouched(vouch: Vouch) { const user = vouch.user() @@ -59,7 +65,7 @@ export class AutoPromoteHandler { ScrimsBot.INSTANCE?.buildSendMessages( PROMOTIONS_CHANNEL, null, - new MessageOptionsBuilder().setContent(`**${user} has been promoted to ${rank}!**`), + new MessageOptionsBuilder().setContent(`${PROMOTION_PREFIX[rank] ?? ""}${user} has been promoted to ${rank}!`), ) } }