Refactor domain handler...