fix subtle bugs in player login