General changes

This commit is contained in:
MattBDev
2016-04-26 10:14:22 -04:00
parent 2c16c767e7
commit 669359cd37
27 changed files with 96 additions and 106 deletions

View File

@@ -298,7 +298,7 @@ public abstract class Command {
MainCommand.getInstance().help.execute(player, args, null, null);
return;
}
} catch (IllegalArgumentException e) {
} catch (IllegalArgumentException ignored) {
}
// Command recommendation
MainUtil.sendMessage(player, C.NOT_VALID_SUBCOMMAND);

View File

@@ -1,31 +0,0 @@
package com.plotsquared.general.commands;
import java.lang.reflect.Field;
public class CommandHandlingOutput {
public static int CALLER_OF_WRONG_TYPE = -6;
public static int NOT_COMMAND = -5;
public static int NOT_FOUND = -4;
public static int NOT_PERMITTED = -3;
public static int ERROR = -2;
public static int WRONG_USAGE = -1;
public static int SUCCESS = 1;
public static String nameField(int code) {
Field[] fields = CommandHandlingOutput.class.getDeclaredFields();
for (Field field : fields) {
if (field.getGenericType() == Integer.TYPE) {
try {
if ((Integer) field.get(CommandHandlingOutput.class) == code) {
return field.getName();
}
} catch (IllegalAccessException e) {
e.printStackTrace();
}
}
}
return "null??";
}
}

View File

@@ -84,7 +84,7 @@ public class WESubscriber {
if (tool instanceof BrushTool) {
hasMask = ((BrushTool) tool).getMask() != null;
}
} catch (Exception e) {
} catch (Exception ignored) {
}
}
AbstractDelegateExtent extent = (AbstractDelegateExtent) event.getExtent();