add basic login logic