Legacy code examples for refactoring