Correct expiring owners query for paid

This commit is contained in:
Rene Vergara 2023-01-24 18:34:22 -06:00
parent 814d4c9ee5
commit bde97f9211
Signed by: pitmutt
GPG Key ID: 65122AD495A7F5B2
1 changed files with 4 additions and 1 deletions

View File

@ -297,4 +297,7 @@ findOwnerById i =
findExpiringOwners :: UTCTime -> Action IO [Document]
findExpiringOwners now =
rest =<<
find (select ["expiration" =: ["$lte" =: addUTCTime 172800 now]] "owners")
find
(select
["paid" =: True, "expiration" =: ["$lte" =: addUTCTime 172800 now]]
"owners")