Progress towards complete refactor.