diff --git a/trytond/trytond/ir/action.py b/trytond/trytond/ir/action.py index de82dc49c6..f86cc9521f 100644 --- a/trytond/trytond/ir/action.py +++ b/trytond/trytond/ir/action.py @@ -685,16 +685,10 @@ class ActionReport( default = {} default = default.copy() default.setdefault('module', None) - - new_reports = [] - for report in reports: - if report.report: - default['report_content'] = None - default['report'] = None - default['report_name'] = report.report_name - new_reports.extend(super(ActionReport, cls).copy([report], - default=default)) - return new_reports + default.setdefault( + 'report_content_custom', + lambda o: None if o['report'] else o['report_content_custom']) + return super().copy(reports, default=default) @classmethod def write(cls, reports, values, *args):