fix bug in RegistrationController