fix register login check