fix log in state ios/ add logging serverside