Handle CommandException in WorldGuardPlugin.convertThrowable().

This commit is contained in:
sk89q 2014-08-14 21:24:02 -07:00
parent e43ce420a3
commit a35cb9277e

View File

@ -351,6 +351,8 @@ public String convertThrowable(@Nullable Throwable throwable) {
return "WorldGuard: Task was interrupted";
} else if (throwable instanceof UnresolvedNamesException) {
return throwable.getMessage();
} else if (throwable instanceof CommandException) {
return throwable.getMessage();
} else {
getLogger().log(Level.WARNING, "WorldGuard encountered an unexpected error", throwable);
return "WorldGuard: An unexpected error occurred! Please see the server console.";