ghostguild-org/app
Jennie Robinson Faber 51230e5151 refactor(launch): simplify launch-readiness fixes
Follow-up to 208638e. Code review surfaced a few real issues; this
commit addresses them.

- login.post.js now uses the new sendMagicLink util instead of
  duplicating the jti/jwt/Resend/logActivity logic. Reduces 60 lines.
- sendMagicLink accepts an optional pre-loaded Member doc, skipping
  the redundant findOne when the caller already has one. customer.post.js
  passes the just-created/upgraded member, dropping signup from 3
  Mongo round-trips to 1 (lookup is gone; jti burn remains).
- sendMagicLink now lowercases the email defensively so callers don't
  have to remember.
- rateLimit.js: replaced an effectively-dead eviction line with a
  probabilistic sweep (~1% of calls scan and evict keys whose newest
  entry has aged out). Caps unbounded Map growth under random-key
  spraying.
- reconcile-payments.post.js: 401/403/404 from Helcim now bails out
  immediately instead of burning all 3 retry attempts; dry-run
  summary filters via the same RECONCILABLE_STATUSES set as apply
  mode so counts match.
- Deleted WHAT-comments and section banners per CLAUDE.md no-comment
  rule. Kept genuine WHY-comments (validateBeforeSave rationale,
  amount-IGNORED-for-tickets, sendConfirmation deliberately-omitted).

Tests: 758/760 passing (unchanged).
2026-04-25 19:34:16 +01:00
..
assets Copy and layout improvements. 2026-04-16 21:11:05 +01:00
components feat(launch): security and correctness fixes for 2026-05-01 launch 2026-04-25 18:42:36 +01:00
composables refactor(launch): simplify launch-readiness fixes 2026-04-25 19:34:16 +01:00
config refactor(contributions): tighten requiresPayment contract; use findLast 2026-04-19 18:10:57 +01:00
layouts Copy and layout improvements. 2026-04-16 21:11:05 +01:00
middleware fix(auth): stop wiki login loop to coming-soon and surface non-member state 2026-04-15 17:55:55 +01:00
pages feat(launch): security and correctness fixes for 2026-05-01 launch 2026-04-25 18:42:36 +01:00
plugins Fix duplicate /api/auth/member call and add request deduplication 2026-03-19 15:04:04 +00:00
utils fix(review): accept arbitrary amounts in payment-setup; rename m.tier → m.amount in activity text 2026-04-19 19:15:32 +01:00
app.config.ts feat: reskin admin pages to zine design system 2026-04-03 10:56:01 +01:00
app.vue feat: replace layout with fixed left sidebar and top strip 2026-04-02 21:11:47 +01:00