Fixed bugs with login Modal Dialog