code refactoring5