From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 From: Jason Penilla <11360596+jpenilla@users.noreply.github.com> Date: Mon, 5 Apr 2021 18:35:15 -0700 Subject: [PATCH] Don't ignore result of PlayerEditBookEvent diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java index cb0c6202b25933aa7770060873c7873f9790f5a1..444c92e067dd20d0e2e9e1b3d249f2a9a8d86c4f 100644 --- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java @@ -1190,7 +1190,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser } itemstack.addTagElement("pages", nbttaglist); - CraftEventFactory.handleEditBookEvent(player, slot, handItem, itemstack); // CraftBukkit + this.player.getInventory().setItem(slot, CraftEventFactory.handleEditBookEvent(player, slot, handItem, itemstack)); // CraftBukkit // Paper - Don't ignore result (see other callsite for handleEditBookEvent) } @Override