Fix for account login

For some reason it stopped working even when the password was correct,
probably regarding to encoding or something like that...