register button bug fix