change login logic