refactoring on report