From 2257f1648c76c4be818bc6f43eefd6f6fdf4c1a9 Mon Sep 17 00:00:00 2001 From: slprime <31038811+slprime@users.noreply.github.com> Date: Sat, 10 Oct 2026 19:04:38 +0300 Subject: [PATCH] Fix NPE in NEI brewery handler when brew can't fill a container (#159) --- .../client/integration/nei/recipe/RecipeHandlerBrewery.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/vazkii/botania/client/integration/nei/recipe/RecipeHandlerBrewery.java b/src/main/java/vazkii/botania/client/integration/nei/recipe/RecipeHandlerBrewery.java index c057f52fc..151d11433 100644 --- a/src/main/java/vazkii/botania/client/integration/nei/recipe/RecipeHandlerBrewery.java +++ b/src/main/java/vazkii/botania/client/integration/nei/recipe/RecipeHandlerBrewery.java @@ -137,7 +137,7 @@ public class RecipeHandlerBrewery extends TemplateRecipeHandler { for (ItemStack emptyContainer : BrewHelper.getBrewContainers()) { final ItemStack filledContainer = recipe.getOutput(emptyContainer); - if (result.isItemEqual(filledContainer) && Objects.equals(result.stackTagCompound, filledContainer.stackTagCompound)) { + if (filledContainer != null && result.isItemEqual(filledContainer) && Objects.equals(result.stackTagCompound, filledContainer.stackTagCompound)) { arecipes.add(new CachedBreweryRecipe(recipe, emptyContainer)); } }