SPIGOT-5038: Inventory.getHolder returns null for wandering traders

This commit is contained in:
md_5 2019-06-07 19:36:40 +10:00
parent 17543ecfd4
commit 123117bd3a

View File

@ -49,7 +49,7 @@
+ }
+
+ public org.bukkit.inventory.InventoryHolder getOwner() {
+ return (merchant instanceof EntityVillager) ? (CraftAbstractVillager) ((EntityVillager) this.merchant).getBukkitEntity() : null;
+ return (merchant instanceof EntityVillagerAbstract) ? (CraftAbstractVillager) ((EntityVillagerAbstract) this.merchant).getBukkitEntity() : null;
+ }
+
+ @Override