login functionality fixed