Added login verification logic.