Mercurial > libervia-backend
changeset 3719:cf930bb282ac
memory (sqla): don't set keys with None as value for RSM in `getItems`
author | Goffi <goffi@goffi.org> |
---|---|
date | Tue, 25 Jan 2022 17:09:11 +0100 |
parents | 16e36f0dd1cb |
children | 40a6374fcd44 |
files | sat/memory/sqla.py |
diffstat | 1 files changed, 6 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/sat/memory/sqla.py Tue Jan 25 17:07:15 2022 +0100 +++ b/sat/memory/sqla.py Tue Jan 25 17:09:11 2022 +0100 @@ -1365,12 +1365,13 @@ else: last = result[-1][1].name - metadata["rsm"] = { - "index": index, - "count": rows_count, - "first": first, - "last": last, + k: v for k, v in { + "index": index, + "count": rows_count, + "first": first, + "last": last, + }.items() if v is not None } metadata["complete"] = index + len(result) == rows_count