In the middle of login implementation