fix recipe type parsing not handling invalid cases

This commit is contained in:
rlnt 2024-10-22 14:33:03 +02:00
parent ebd1db2d37
commit 1f33027062
No known key found for this signature in database

View file

@ -27,7 +27,7 @@ public class RecipeLink implements RecipeData {
this.originalRecipe = originalRecipe; this.originalRecipe = originalRecipe;
try { try {
this.type = ResourceLocation.tryParse(originalRecipe.get("type").getAsString()); this.type = ResourceLocation.parse(originalRecipe.get("type").getAsString());
} catch (Exception e) { } catch (Exception e) {
throw new IllegalArgumentException("could not detect recipe type"); throw new IllegalArgumentException("could not detect recipe type");
} }