mirror of
https://github.com/darksaid98/HuskHomes.git
synced 2026-12-02 14:38:52 +00:00
Continue command refactor work
This commit is contained in:
31 files changed
+319
-391
No files matched your search
@@ -62,7 +62,8 @@ public class WarpCommand extends Command implements TabProvider, ConsoleExecutab
|
||||
}
|
||||
|
||||
@Override
|
||||
public @NotNull List<String> suggest(@NotNull String[] args, @Nullable OnlineUser user) {
|
||||
@NotNull
|
||||
public final List<String> suggest(@NotNull CommandUser user, @NotNull String[] args) {
|
||||
return plugin.getCache().getWarps().stream()
|
||||
.filter(s -> user == null || Warp.hasPermission(plugin.getSettings().isPermissionRestrictWarps(), user, s))
|
||||
.filter(s -> s.toLowerCase().startsWith(args.length >= 1 ? args[0].toLowerCase() : ""))
|
||||
|
||||
Reference in new issue
Block a user