diff-view refactoring