Fixing login and register