Fix login logic & toast.