extending logic to visiting the registration page