SteamWar/BauSystem2.0
Archiviert
12
0

Fix SkullCommand
Alle Prüfungen waren erfolgreich
SteamWarCI Build successful

Signed-off-by: yoyosource <yoyosource@nidido.de>
Dieser Commit ist enthalten in:
yoyosource 2022-06-13 22:49:24 +02:00
Ursprung 7514728a72
Commit 701cc4611e

Datei anzeigen

@ -57,12 +57,13 @@ public class SkullCommand extends SWCommand {
return new TypeMapper<String>() { return new TypeMapper<String>() {
@Override @Override
public String map(CommandSender commandSender, String[] previousArguments, String s) { public String map(CommandSender commandSender, String[] previousArguments, String s) {
if (s.endsWith("")) return null;
return s; return s;
} }
@Override @Override
public List<String> tabCompletes(CommandSender commandSender, String[] strings, String s) { public List<String> tabCompletes(CommandSender commandSender, String[] strings, String s) {
return Bukkit.getOnlinePlayers().stream().map(Player::getName).collect(Collectors.toList()); return Bukkit.getOnlinePlayers().stream().map(Player::getName).filter(s1 -> !s1.endsWith("")).collect(Collectors.toList());
} }
}; };
} }