refactoring examples