Skip to content

Commit

Permalink
🐛 fix(Tesseract): Check if menu == null when updating items in a menu.
Browse files Browse the repository at this point in the history
…Fixes #216
  • Loading branch information
ProfElements committed Sep 9, 2024
1 parent 53004fb commit 7bee932
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -211,6 +211,10 @@ public int getGeneratedOutput(Location l, Config data) {
}

private void updateKnowledgePane(BlockMenu menu, int currentCharge) {
if (menu == null) {
return;
}

ItemStack knowledgePane = menu.getItemInSlot(4);
ItemMeta im = knowledgePane.getItemMeta();
List<String> lore = im.hasLore() ? im.getLore() : new ArrayList<>();
Expand Down

0 comments on commit 7bee932

Please sign in to comment.