Fix check login user function