Fix bug in client/server