Added starting login logic