mirror of
https://github.com/EngineHub/WorldGuard.git
synced 2024-11-14 22:56:18 +01:00
Wrap and unwrap.
Exceptions are fun.
This commit is contained in:
parent
a29afe8cc1
commit
23ab79c999
@ -223,7 +223,13 @@ public boolean onCommand(CommandSender sender, Command cmd, String label, String
|
||||
} catch (Throwable t) {
|
||||
Throwable next = t;
|
||||
do {
|
||||
WorldGuard.getInstance().getExceptionConverter().convert(next);
|
||||
try {
|
||||
WorldGuard.getInstance().getExceptionConverter().convert(next);
|
||||
} catch (org.enginehub.piston.exception.CommandException pce) {
|
||||
if (pce.getCause() instanceof CommandException) {
|
||||
throw ((CommandException) pce.getCause());
|
||||
}
|
||||
}
|
||||
next = next.getCause();
|
||||
} while (next != null);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user