Fixed registration and log in issue