From 204f9d2e31ccd3014f4737b2b6ca8296fb0a6eaf Mon Sep 17 00:00:00 2001 From: Brady Date: Sat, 21 Sep 2019 17:25:20 -0500 Subject: [PATCH] Fix redundant Stream.of usage --- .../java/baritone/api/utils/command/BaritoneChatControl.java | 4 ++-- .../java/baritone/utils/command/defaults/GoalCommand.java | 2 +- src/main/java/baritone/utils/command/defaults/SetCommand.java | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/api/java/baritone/api/utils/command/BaritoneChatControl.java b/src/api/java/baritone/api/utils/command/BaritoneChatControl.java index 4fbd93aba..5a54d4eb8 100644 --- a/src/api/java/baritone/api/utils/command/BaritoneChatControl.java +++ b/src/api/java/baritone/api/utils/command/BaritoneChatControl.java @@ -194,9 +194,9 @@ public class BaritoneChatControl implements Helper, AbstractGameEventListener { if (setting.getValueClass() == Boolean.class) { TabCompleteHelper helper = new TabCompleteHelper(); if ((Boolean) setting.value) { - helper.append(Stream.of("true", "false")); + helper.append("true", "false"); } else { - helper.append(Stream.of("false", "true")); + helper.append("false", "true"); } return helper.filterPrefix(argc.getString()).stream(); } else { diff --git a/src/main/java/baritone/utils/command/defaults/GoalCommand.java b/src/main/java/baritone/utils/command/defaults/GoalCommand.java index 23065deb5..6ba7a995c 100644 --- a/src/main/java/baritone/utils/command/defaults/GoalCommand.java +++ b/src/main/java/baritone/utils/command/defaults/GoalCommand.java @@ -63,7 +63,7 @@ public class GoalCommand extends Command { protected Stream tabCompleted(String label, ArgConsumer args) throws CommandException { TabCompleteHelper helper = new TabCompleteHelper(); if (args.hasExactlyOne()) { - helper.append(Stream.of("reset", "clear", "none", "~")); + helper.append("reset", "clear", "none", "~"); } else { if (args.hasAtMost(3)) { while (args.has(2)) { diff --git a/src/main/java/baritone/utils/command/defaults/SetCommand.java b/src/main/java/baritone/utils/command/defaults/SetCommand.java index f3baeeb20..f55b213bc 100644 --- a/src/main/java/baritone/utils/command/defaults/SetCommand.java +++ b/src/main/java/baritone/utils/command/defaults/SetCommand.java @@ -207,9 +207,9 @@ public class SetCommand extends Command { if (setting.getType() == Boolean.class) { TabCompleteHelper helper = new TabCompleteHelper(); if ((Boolean) setting.value) { - helper.append(Stream.of("true", "false")); + helper.append("true", "false"); } else { - helper.append(Stream.of("false", "true")); + helper.append("false", "true"); } return helper.filterPrefix(args.getString()).stream(); } else {