diff options
author | Florian Dold <florian.dold@gmail.com> | 2020-08-05 19:43:11 +0530 |
---|---|---|
committer | Florian Dold <florian.dold@gmail.com> | 2020-08-05 19:43:11 +0530 |
commit | 76f7430dd17201095372c576b1002683879a3b4d (patch) | |
tree | 299359a63962dad07129fd8a7c6d7507df585f35 | |
parent | 7aa2b2f1c088da52540d55877edd7921cc55ed54 (diff) | |
download | bank-76f7430dd17201095372c576b1002683879a3b4d.tar.gz bank-76f7430dd17201095372c576b1002683879a3b4d.tar.bz2 bank-76f7430dd17201095372c576b1002683879a3b4d.zip |
extract reserve pub, so that other transactions to the exchange don't break it
-rw-r--r-- | talerbank/app/views.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/talerbank/app/views.py b/talerbank/app/views.py index b450fc7..b55e487 100644 --- a/talerbank/app/views.py +++ b/talerbank/app/views.py @@ -899,12 +899,15 @@ def twg_history_incoming(request, user_account, acct_id): start = int(start_str) qs = query_history(user_account.bankaccount, "credit", delta, start,) for item in qs: + rp = get_reserve_pub(item.subject) + if rp is None: + continue history.append( dict( row_id=item.id, amount=item.amount.stringify(settings.TALER_DIGITS), date=dict(t_ms=(int(item.date.timestamp()) * 1000)), - reserve_pub=item.subject, + reserve_pub=rp, credit_account=get_payto_from_account(request, item.credit_account), debit_account=get_payto_from_account(request, item.debit_account), ) |