Story 4: refactoring