reward more of the post/comment tail
This commit is contained in:
parent
2d0f21fb20
commit
25d2c58559
|
@ -3,7 +3,7 @@ const { ANON_USER_ID } = require('../lib/constants')
|
|||
|
||||
// const ITEM_EACH_REWARD = 3.0
|
||||
// const UPVOTE_EACH_REWARD = 6.0
|
||||
const TOP_PERCENTILE = 21
|
||||
const TOP_PERCENTILE = 33
|
||||
const TOTAL_UPPER_BOUND_MSATS = 1000000000
|
||||
const REDUCE_REWARDS = [616, 6030, 946, 4502]
|
||||
|
||||
|
@ -18,7 +18,8 @@ function earn ({ models }) {
|
|||
(SELECT ("ItemAct".msats - COALESCE("ReferralAct".msats, 0)) as msats
|
||||
FROM "ItemAct"
|
||||
LEFT JOIN "ReferralAct" ON "ReferralAct"."itemActId" = "ItemAct".id
|
||||
WHERE date_trunc('day', "ItemAct".created_at AT TIME ZONE 'UTC' AT TIME ZONE 'America/Chicago') = date_trunc('day', (now() - interval '1 day') AT TIME ZONE 'America/Chicago') AND "ItemAct".act <> 'TIP')
|
||||
WHERE date_trunc('day', "ItemAct".created_at AT TIME ZONE 'UTC' AT TIME ZONE 'America/Chicago') = date_trunc('day', (now() - interval '1 day') AT TIME ZONE 'America/Chicago')
|
||||
AND "ItemAct".act <> 'TIP')
|
||||
UNION ALL
|
||||
(SELECT sats * 1000 as msats
|
||||
FROM "Donation"
|
||||
|
|
Loading…
Reference in New Issue