Commit 6a53adf1 authored by Damien Mat's avatar Damien Mat Committed by Vincent A

[lcl] Fix: avoid AttributeError on transactions page

When amount is not found by the first parsing,
it must be done by a second one.
I changed the condition on which this is triggered,
since it not needed anymore,
and would throw an AttributeError when page is parsed a second time.
parent ca86b06f
......@@ -645,7 +645,7 @@ class AccountHistoryPage(LoggedPage, HTMLPage):
# ugly hack to fix broken html
# sometimes transactions have really an amount of 0...
if not obj.amount and CleanDecimal(TableCell('credit'), default=None)(self) is None:
if not obj.amount:
if tr_page:
# TODO move this xpath to the relevant page class
obj.amount = CleanDecimal(
......
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