complete the fuction user login