mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-06-07 12:18:46 +00:00
Fix deepEquals() crash when tag check is specified and only one item has a tag (#188)
This commit is contained in:
parent
8db4b7116c
commit
6a066cdf31
@ -756,7 +756,7 @@ class Item implements ItemIds, \JsonSerializable{
|
||||
public final function deepEquals(Item $item, bool $checkDamage = true, bool $checkCompound = true) : bool{
|
||||
if($this->equals($item, $checkDamage, $checkCompound)){
|
||||
return true;
|
||||
}elseif($item->hasCompoundTag() or $this->hasCompoundTag()){
|
||||
}elseif($item->hasCompoundTag() and $this->hasCompoundTag()){
|
||||
return NBT::matchTree($this->getNamedTag(), $item->getNamedTag());
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user