fixes bug while adding player.