mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-05 17:36:12 +00:00
Destroy cycles that reference player for faster collection
This commit is contained in:
@ -2911,8 +2911,16 @@ class Player extends Human implements CommandSender, InventoryHolder, ChunkLoade
|
||||
|
||||
if($this->perm !== null){
|
||||
$this->perm->clearPermissions();
|
||||
$this->perm = null;
|
||||
}
|
||||
|
||||
if($this->inventory !== null){
|
||||
$this->inventory = null;
|
||||
$this->currentTransaction = null;
|
||||
}
|
||||
|
||||
$this->chunk = null;
|
||||
|
||||
$this->server->removePlayer($this);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user