fixed javascript login