Refactor domains