Referral card: count someone as brought on the day they joined InstantAdPay, not the day this directory first saw them

The backfill stamped firstSeen at seeding time, so every hunter already on the
board read as brought in today.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
martbost
2026-09-23 04:43:34 -05:00
parent 1c9e99f91e
commit 48611374d6
+3 -1
View File
@@ -139,7 +139,9 @@ function state(member) {
const paid = bountyPaidFor(x.memberId); const paid = bountyPaidFor(x.memberId);
return { return {
name: x.username || ('#' + x.memberId), name: x.username || ('#' + x.memberId),
joinedAt: x.firstSeen || null, // when they actually joined InstantAdPay, not when this directory first noticed them:
// the backfill stamped firstSeen at seeding time and made everyone look brought-in today
joinedAt: x.joinedAt || x.firstSeen || null,
finds: theirFinds.length, finds: theirFinds.length,
state: paid ? 'earning' : theirFinds.length ? 'hunting' : 'signed up, no find yet', state: paid ? 'earning' : theirFinds.length ? 'hunting' : 'signed up, no find yet',
stillNew: x.joinedAt ? (Date.now() - Number(x.joinedAt)) / 86400000 <= Number(c.refMatchDays) : false, stillNew: x.joinedAt ? (Date.now() - Number(x.joinedAt)) / 86400000 <= Number(c.refMatchDays) : false,