Catch all when merging jars

dev/0.11
modmuss50 2021-05-12 20:31:05 +01:00
parent 258578f142
commit 2f38c747a1
1 changed files with 2 additions and 3 deletions

View File

@ -31,7 +31,6 @@ import java.net.URL;
import java.nio.charset.StandardCharsets;
import java.util.Optional;
import java.util.function.Consumer;
import java.util.zip.ZipError;
import com.google.common.io.Files;
import com.google.gson.GsonBuilder;
@ -101,13 +100,13 @@ public class MinecraftProvider extends DependencyProvider {
if (!minecraftMergedJar.exists() || isRefreshDeps()) {
try {
mergeJars(getProject().getLogger());
} catch (ZipError e) {
} catch (Throwable e) {
HashedDownloadUtil.delete(minecraftClientJar);
HashedDownloadUtil.delete(minecraftServerJar);
minecraftMergedJar.delete();
getProject().getLogger().error("Could not merge JARs! Deleting source JARs - please re-run the command and move on.", e);
throw new RuntimeException();
throw e;
}
}
}