another simple refactoring with a large diff; all tests still pass