Correct typo: Use limit instead of count.

count returns the number of found reports, but we search for the first
ActionReport instance.
This commit is contained in:
Mathias Behrle 2025-01-27 08:35:30 +01:00
parent a6423b88e1
commit f9f9901fc1

View file

@ -105,7 +105,7 @@ class XReport(Report):
# no report defined, use 1st found
act_report = ActionReport.search([
('model', '=', 'account.invoice'),
('extension', '=', 'pdf')], count=1)
('extension', '=', 'pdf')], limit=1)
if act_report:
act_report = act_report[0]
if not act_report: