Spaces in pom + optimizations

This commit is contained in:
Gabriele C 2015-08-02 14:22:34 +02:00
parent 5ac5bfc9a4
commit acbae36ddf
4 changed files with 542 additions and 582 deletions

1114
pom.xml

File diff suppressed because it is too large Load Diff

View File

@ -120,6 +120,7 @@ public class AuthMe extends JavaPlugin {
this.database = database;
}
@SuppressWarnings("deprecation")
@Override
public void onEnable() {
authme = this;

View File

@ -504,7 +504,8 @@ public class FileCache {
armours[i] = attributes.getStack();
else armours[i] = item;
}
} catch (final RuntimeException e) {
ConsoleLogger.showError("Error while reading file for " + player.getName() + ", some wipe inventory incoming...");
} catch (final Exception e) {
ConsoleLogger.showError("Error while reading file for " + player.getName() + ", some wipe inventory incoming...");
} finally {
@ -513,6 +514,9 @@ public class FileCache {
}
return new DataFileCache(inv, armours, group, op, flying);
}
} catch (RuntimeException e) {
ConsoleLogger.showError("Error while reading file for " + player.getName() + ", some wipe inventory incoming...");
return null;
} catch (Exception e) {
ConsoleLogger.showError("Error while reading file for " + player.getName() + ", some wipe inventory incoming...");
return null;

View File

@ -477,6 +477,7 @@ public class AdminCommand implements CommandExecutor {
m.send(sender, "error");
return true;
}
@SuppressWarnings("deprecation")
Player target = Bukkit.getPlayer(name);
PlayerCache.getInstance().removePlayer(name);
Utils.getInstance().setGroup(name, groupType.UNREGISTERED);
@ -559,6 +560,7 @@ public class AdminCommand implements CommandExecutor {
sender.sendMessage("Usage: /authme getip <onlineplayername>");
return true;
}
@SuppressWarnings("deprecation")
Player player = Bukkit.getPlayer(args[1]);
if (player == null) {
sender.sendMessage("This player is not actually online");
@ -574,6 +576,7 @@ public class AdminCommand implements CommandExecutor {
return true;
}
try {
@SuppressWarnings("deprecation")
Player player = Bukkit.getPlayer(args[1]);
if (player == null || !player.isOnline()) {
sender.sendMessage("Player needs to be online!");