refactor
All 3 tests pass