fix user register bugs