Wrap and unwrap.

Exceptions are fun.
This commit is contained in:
wizjany
2019-05-29 21:38:37 -04:00
parent 27b58f4e85
commit ec3648e521
2 changed files with 4 additions and 1 deletions

View File

@ -76,6 +76,9 @@ public abstract class ExceptionConverterHelper implements ExceptionConverter {
if (e.getCause() instanceof CommandException) {
throw (CommandException) e.getCause();
}
if (e.getCause() instanceof com.sk89q.minecraft.util.commands.CommandException) {
throw new CommandException(e.getCause(), ImmutableList.of());
}
throw new CommandExecutionException(e, ImmutableList.of());
} catch (IllegalArgumentException | IllegalAccessException e) {
throw new CommandExecutionException(e, ImmutableList.of());