diff --git a/erpnext/controllers/accounts_controller.py b/erpnext/controllers/accounts_controller.py index 28070d2377..e689d567a1 100644 --- a/erpnext/controllers/accounts_controller.py +++ b/erpnext/controllers/accounts_controller.py @@ -1174,7 +1174,7 @@ class AccountsController(TransactionBase): ) if ( - (enable_discount_accounting or self.is_cash_or_non_trade_discount) + (enable_discount_accounting or self.get("is_cash_or_non_trade_discount")) and self.get("additional_discount_account") and self.get("discount_amount") ):