Fixed login duplication bug