Merge pull request #36077 from frappe/mergify/bp/version-14-hotfix/pr-36076

fix: possible type error on ERR creation (backport #36076)
This commit is contained in:
ruthra kumar
2023-07-11 11:12:24 +05:30
committed by GitHub

View File

@@ -258,8 +258,8 @@ class ExchangeRateRevaluation(Document):
new_balance_in_base_currency = 0
new_balance_in_account_currency = 0
current_exchange_rate = calculate_exchange_rate_using_last_gle(
company, d.account, d.party_type, d.party
current_exchange_rate = (
calculate_exchange_rate_using_last_gle(company, d.account, d.party_type, d.party) or 0.0
)
gain_loss = new_balance_in_account_currency - (