client refactor, answer from server refactored