Fix: get_payments crud default Filter values. (#1703)

* get_payments: deafult values for filter

* lololololoolol
This commit is contained in:
callebtc 2023-05-11 18:36:20 +02:00 committed by GitHub
parent b6223f0e6d
commit e39241a9e9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -426,11 +426,10 @@ async def get_payments(
Filters payments to be returned by complete | pending | outgoing | incoming. Filters payments to be returned by complete | pending | outgoing | incoming.
""" """
if not filters: filters = filters or Filters()
filters = Filters()
filters.sortby = "time" or filters.sortby filters.sortby = filters.sortby or "time"
filters.direction = "desc" or filters.direction filters.direction = filters.direction or "desc"
filters.limit = limit or filters.limit filters.limit = limit or filters.limit
filters.offset = offset or filters.offset filters.offset = offset or filters.offset