Fixed PlayerInventory in_array recursion issue, close #1008

This is INTENDED BEHAVIOUR for comparing objects?????
This commit is contained in:
Dylan K. Taylor 2017-06-05 20:51:12 +01:00
parent b9a87ed147
commit 6ea0eb47ec

View File

@ -245,7 +245,7 @@ class PlayerInventory extends BaseInventory{
}
}else{
$this->getHolder()->getLevel()->getServer()->broadcastPacket($target, $pk);
if($this->getHeldItemSlot() !== -1 and in_array($this->getHolder(), $target)){
if($this->getHeldItemSlot() !== -1 and in_array($this->getHolder(), $target, true)){
$this->sendSlot($this->getHeldItemSlot(), $this->getHolder());
}
}