How to deal with different log in input?