refactor: use isinstance over type

This commit is contained in:
ruthra kumar 2023-10-03 17:38:43 +05:30
parent 1dab195560
commit 67440c38ae

View File

@ -99,7 +99,7 @@ class AccountsReceivableSummary(ReceivablePayableReport):
# Add all amount columns
for k in list(self.party_total[d.party]):
if type(self.party_total[d.party][k]) == float:
if isinstance(self.party_total[d.party][k], float):
self.party_total[d.party][k] += d.get(k) or 0.0
# set territory, customer_group, sales person etc