Remove duplication

This commit is contained in:
Bea 2022-12-20 15:04:39 +01:00
parent c4d81fb0e4
commit 7dcdf9dbde
3 changed files with 4 additions and 5 deletions

View File

@ -150,7 +150,7 @@ public class ClearChat
public static Button getDismissButton()
{
return Button.primary("clear_dismiss", "Dismiss")
return Button.primary("generic_dismiss", "Dismiss")
.withEmoji(Emoji.fromUnicode(""));
}

View File

@ -45,7 +45,7 @@ public class UrbanDictionary
public static Button getDeleteButton()
{
return Button.danger("urban_delete", "Delete")
return Button.danger("generic_dismiss", "Delete")
.withEmoji(Emoji.fromFormatted("\uD83D\uDDD1"));
}

View File

@ -18,13 +18,12 @@ public class ButtonInteractionListener extends ListenerAdapter
// coinflip
case "coinflip_reflip" -> CoinFlip.buttonReFlip(event);
// clearchat command
case "clear_dismiss" -> CommandUtil.delete(event);
// generic dismiss button
case "generic_dismiss" -> CommandUtil.delete(event);
// urban dictionary navigation
case "urban_nextpage" -> UrbanDictionary.changePage(event, true);
case "urban_previouspage" -> UrbanDictionary.changePage(event, false);
case "urban_delete" -> CommandUtil.delete(event);
}