Extract common signIn logic to controller