Refactor begins