changeset 8c2c281a6531 in modules/account_deposit:default
details: 
https://hg.tryton.org/modules/account_deposit?cmd=changeset&node=8c2c281a6531
description:
        Replace cursor fetchall by iteration over cursor

        issue5817
        review335831003
diffstat:

 party.py |  2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diffs (12 lines):

diff -r 617038b1be6a -r 8c2c281a6531 party.py
--- a/party.py  Sat Mar 13 23:14:19 2021 +0100
+++ b/party.py  Sun Mar 21 16:09:13 2021 +0100
@@ -60,7 +60,7 @@
                     & (account.company == user.company.id)
                     & line_clause,
                     group_by=line.party))
-            for party_id, value in cursor.fetchall():
+            for party_id, value in cursor:
                 # SQLite uses float for SUM
                 if not isinstance(value, Decimal):
                     value = currency.round(Decimal(str(value)))

Reply via email to