mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-04-21 00:07:30 +00:00
InventoryManager: ensure the windowID is valid before attempting to remove any window
this is currently a harmless bug, since remove() isn't currently doing any heavy lifting.
This commit is contained in:
parent
ed7c95549d
commit
def2f8c145
@ -259,7 +259,7 @@ class InventoryManager{
|
||||
|
||||
public function onClientRemoveWindow(int $id) : void{
|
||||
if($id === $this->lastInventoryNetworkId){
|
||||
if($id !== $this->pendingCloseWindowId){
|
||||
if(isset($this->windowMap[$id]) && $id !== $this->pendingCloseWindowId){
|
||||
$this->remove($id);
|
||||
$this->player->removeCurrentWindow();
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user