11import {
22 type AnySelectMenuInteraction ,
33 ApplicationCommandType ,
4+ type ApplicationEmoji ,
45 type AutocompleteInteraction ,
56 type ButtonInteraction ,
67 type ChatInputCommandInteraction ,
@@ -115,7 +116,13 @@ export class StelliaUtils<EmojiEnum extends Record<string, string> = Record<stri
115116 }
116117 } ;
117118
118- public getGuildConfiguration = < CustomGuildConfiguration extends GuildConfiguration > ( guildId : string ) : CustomGuildConfiguration | null => {
119+ public getCustomEmoji = ( emojiName : string ) : ApplicationEmoji | undefined => {
120+ return this . client . customEmojis [ emojiName ] ;
121+ } ;
122+
123+ public getGuildConfiguration = < CustomGuildConfiguration extends GuildConfiguration > (
124+ guildId : string
125+ ) : CustomGuildConfiguration | null => {
119126 if ( ! this . client . environment ?. areGuildsConfigurationEnabled || ! this . guildsConfiguration ) {
120127 return null ;
121128 }
@@ -297,7 +304,9 @@ export class StelliaUtils<EmojiEnum extends Record<string, string> = Record<stri
297304 return ;
298305 }
299306
300- const selectMenu = selectMenuManager . getByCustomId ( selectMenuInteraction . customId ) || selectMenuManager . getByRegex ( selectMenuInteraction . customId ) ;
307+ const selectMenu =
308+ selectMenuManager . getByCustomId ( selectMenuInteraction . customId ) ||
309+ selectMenuManager . getByRegex ( selectMenuInteraction . customId ) ;
301310 if ( ! selectMenu ) {
302311 return ;
303312 }
@@ -320,7 +329,9 @@ export class StelliaUtils<EmojiEnum extends Record<string, string> = Record<stri
320329 }
321330 } ;
322331
323- private readonly handleMessageContextMenuInteraction = async ( interaction : MessageContextMenuCommandInteraction < "cached" > ) : Promise < void > => {
332+ private readonly handleMessageContextMenuInteraction = async (
333+ interaction : MessageContextMenuCommandInteraction < "cached" >
334+ ) : Promise < void > => {
324335 try {
325336 const contextMenuManager = this . client . managers . contextMenus ;
326337 if ( ! contextMenuManager ) {
0 commit comments