mirror of
https://github.com/BentoBoxWorld/BSkyBlock.git
synced 2024-09-24 03:33:40 +02:00
Use control panel if it exists.
This commit is contained in:
parent
5b25c2ddc8
commit
cf04358d14
@ -73,6 +73,9 @@ public class IslandCommand extends CompositeCommand {
|
||||
if (args.isEmpty()) {
|
||||
// If user has an island, go
|
||||
if (getPlugin().getIslands().getIsland(getWorld(), user.getUniqueId()) != null) {
|
||||
if (getSubCommand("controlpanel").isPresent()) {
|
||||
return getSubCommand("controlpanel").get().call(user, label, new ArrayList<>());
|
||||
}
|
||||
return getSubCommand("go").map(goCmd -> goCmd.call(user, goCmd.getLabel(), new ArrayList<>())).orElse(false);
|
||||
}
|
||||
// No islands currently
|
||||
|
Loading…
Reference in New Issue
Block a user