fix: ensure list has items

(cherry picked from commit e13e688987)
This commit is contained in:
Sagar Vora
2024-11-06 14:04:30 +05:30
committed by Mergify
parent 36b22e290a
commit 633997b1b0

View File

@@ -439,7 +439,7 @@ def split_invoices(invoices):
continue
return_against_is_added = any(
d for d in _invoices if d[0].pos_invoice == pos_invoice.return_against
d for d in _invoices if d and d[0].pos_invoice == pos_invoice.return_against
)
if return_against_is_added:
break