fixed bug for user login