fix refactor breaking a test