Bug fixes to remember me functionality