Fix build (whoops)

This commit is contained in:
Luck 2017-10-12 20:21:49 +01:00
parent 3b74d55442
commit 1a5f9683c2
No known key found for this signature in database
GPG Key ID: EFA9B3EC5FD90F8B
2 changed files with 8 additions and 11 deletions

View File

@ -40,7 +40,6 @@ import me.lucko.luckperms.common.plugin.LuckPermsPlugin;
import me.lucko.luckperms.common.utils.DateUtil;
import me.lucko.luckperms.common.utils.Predicates;
import java.util.LinkedHashMap;
import java.util.List;
import java.util.Map;
import java.util.stream.Collectors;
@ -83,14 +82,12 @@ public class InfoCommand extends SingleCommand {
plugin.getCalculatorFactory().getActiveProcessors().stream().collect(Collectors.joining(", "))
);
LinkedHashMap<String, Object> platformInfo = plugin.getExtraInfo();
if (platformInfo == null || platformInfo.isEmpty()) {
return CommandResult.SUCCESS;
}
Message.EMPTY.send(sender, "&f- &bPlatform Info:");
for (Map.Entry<String, Object> e : platformInfo.entrySet()) {
Message.EMPTY.send(sender, "&f- &3" + e.getKey() + ": " + formatValue(e.getValue().toString()));
Map<String, Object> platformInfo = plugin.getExtraInfo();
if (!platformInfo.isEmpty()) {
Message.EMPTY.send(sender, "&f- &bPlatform Info:");
for (Map.Entry<String, Object> e : platformInfo.entrySet()) {
Message.EMPTY.send(sender, "&f- &3" + e.getKey() + ": " + formatValue(e.getValue().toString()));
}
}
return CommandResult.SUCCESS;

View File

@ -376,10 +376,10 @@ public interface LuckPermsPlugin {
/**
* Gets a map of extra information to be shown in the info command
*
* @return a map of options, or null
* @return a map of options
*/
default Map<String, Object> getExtraInfo() {
return null;
return Collections.emptyMap();
}
/**