Final refactor.