Fix crash after player leaves