commit | 546c809cbeead2b556b3b09b632f3d73a500900e | [log] [tgz] |
---|---|---|
author | Sabu Siyad <hello@ssiyad.com> | Thu Nov 17 17:46:49 2022 +0530 |
committer | Sabu Siyad <hello@ssiyad.com> | Thu Nov 17 17:46:49 2022 +0530 |
tree | f6021306e6c8988b5e936bc297206c7b48df88cc | |
parent | fd3c7903ba454b163b97c5040b49951a7ac4eb4d [diff] [blame] |
fix: use `list()` on self mutating iteration https://github.com/frappe/erpnext/issues/30325 Signed-off-by: Sabu Siyad <hello@ssiyad.com>
diff --git a/erpnext/erpnext_integrations/taxjar_integration.py b/erpnext/erpnext_integrations/taxjar_integration.py index b8893aa..2d9093b 100644 --- a/erpnext/erpnext_integrations/taxjar_integration.py +++ b/erpnext/erpnext_integrations/taxjar_integration.py
@@ -302,7 +302,7 @@ item.tax_collectable = flt(0) item.taxable_amount = flt(0) - for tax in doc.taxes: + for tax in list(doc.taxes): if tax.account_head == TAX_ACCOUNT_HEAD: doc.taxes.remove(tax) return