We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent be3d9a6 commit b605124Copy full SHA for b605124
worker/earn.js
@@ -25,7 +25,8 @@ export async function earn ({ name }) {
25
SELECT sum("msats") as "msats"
26
FROM "AggRewards"
27
WHERE date_trunc('day', "timeBucket") = date_trunc('day', now() AT TIME ZONE 'America/Chicago' - interval '1 day')
28
- AND "payInType" IS NULL`
+ AND "payInType" IS NULL
29
+ AND granularity = 'DAY'`
30
31
if (!totalMsatsDecimal || totalMsatsDecimal.lessThanOrEqualTo(0)) {
32
throw new Error('no rewards to distribute')
0 commit comments