Yet more re-factoring.