customer refactoring