Fixed double login bug