Skip to content

Commit 0e307f9

Browse files
author
Fischstaebchen
committed
changed the value for the OptionMapping to match the Enum constants.
1 parent c5ac310 commit 0e307f9

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/main/java/net/javadiscord/javabot/systems/user_commands/format_code/FormatCodeCommand.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -48,9 +48,9 @@ public FormatCodeCommand() {
4848
.addChoice("TypeScript", "typescript")
4949
.addChoice("XML", "xml"),
5050
new OptionData(OptionType.STRING,"auto-indent","The type of indentation applied to the message, does not automatically indent if left blank.",false)
51-
.addChoice("Four_Spaces","four")
52-
.addChoice("Two_Spaces","two")
53-
.addChoice("Tabs","tab")
51+
.addChoice("Four Spaces","FOUR_SPACES")
52+
.addChoice("Two Spaces","TWO_SPACES")
53+
.addChoice("Tabs","TABS")
5454
)
5555
);
5656
}
@@ -65,7 +65,7 @@ public FormatCodeCommand() {
6565
public void execute(@NotNull SlashCommandInteractionEvent event) {
6666
OptionMapping idOption = event.getOption("message-id");
6767
String format = event.getOption("format", "java", OptionMapping::getAsString);
68-
String indentation = event.getOption("auto-indent","null",OptionMapping::getAsString).toUpperCase();
68+
String indentation = event.getOption("auto-indent","null",OptionMapping::getAsString);
6969
event.deferReply().queue();
7070
if (idOption == null) {
7171
event.getChannel().getHistory()

0 commit comments

Comments
 (0)