Fixed non-redirection in case of error in user registration.