Commit 706380ef authored by Guillaume Risbourg's avatar Guillaume Risbourg Committed by Vincent A

[bnporc] Fixed error for loans with empty balance

Closes: 12994@zendesk 43878@sibi
Listed in: 12974@zendesk
parent 3fba711d
......@@ -315,6 +315,12 @@ class AccountsPage(BNPPage):
item_xpath = 'compte'
class item(ItemElement):
def validate(self, obj):
# We skip loans with a balance of 0 because the JSON returned gives
# us no info (only `null` values on all fields), so there is nothing
# useful to display
return obj.type != Account.TYPE_LOAN or obj.balance != 0
2: Account.TYPE_SAVINGS,
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment