Move command handling out of constructor, add coin reflip command
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
Having heavy code run in a constructor is bad practice. We made separate methods for command handling.
This commit is contained in:
@@ -8,7 +8,7 @@ import wtf.beatrice.hidekobot.Configuration;
|
||||
|
||||
public class InviteCommand
|
||||
{
|
||||
public InviteCommand(@NotNull SlashCommandInteractionEvent event)
|
||||
public void runSlashCommand(@NotNull SlashCommandInteractionEvent event)
|
||||
{
|
||||
ReplyCallbackAction reply = event.reply("Here's your link ✨ " + Configuration.getInviteUrl());
|
||||
|
||||
|
Reference in New Issue
Block a user