Minor refacturing of AuthenticateActivity