fix login redirects to actually work properly