Changeset c628dcd4 in Klonkt for src/routes
- Timestamp:
- 07/28/2026 06:43:39 AM (6 weeks ago)
- Branches:
- main
- Children:
- 6bc2e31b
- Parents:
- de89079
- Location:
- src/routes
- Files:
-
- 2 edited
-
guardian.js (modified) (1 diff)
-
paid.js (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
src/routes/guardian.js
rde89079 rc628dcd4 38 38 function uiStrings(L) { 39 39 const keys = ['sent', 'sent_retry', 'sending', 'not_found', 'failed', 'network', 40 'pending', 'active', 'retract', 'release', ' open', 'push_unavailable',40 'pending', 'active', 'retract', 'release', 'release_confirm', 'open', 'push_unavailable', 41 41 'accept', 'reject', 'complete', 'awaiting_others', 'coguard']; 42 42 const s = Object.fromEntries(keys.map((k) => [k, i18nT(L, `guardian.${k}`)])); -
src/routes/paid.js
rde89079 rc628dcd4 54 54 if (!payload || payload.purpose !== 'patron' || payload.siteId !== r.site.id) { 55 55 return renderPage(req, res, 'pages/paid-result', { 56 pageTitleKey: 'pres.t', bodyClass: 'on- special', ok: false, reason: 'expired',56 pageTitleKey: 'pres.t', bodyClass: 'on-post', ok: false, reason: 'expired', 57 57 }); 58 58 } … … 60 60 const code = String(req.query.code || ''); 61 61 if (req.query.error || !code) { 62 return renderPage(req, res, 'pages/paid-result', { pageTitleKey: 'pres.t', bodyClass: 'on- special', ok: false, reason: 'declined', postSlug: payload.post, patronUrl });62 return renderPage(req, res, 'pages/paid-result', { pageTitleKey: 'pres.t', bodyClass: 'on-post', ok: false, reason: 'declined', postSlug: payload.post, patronUrl }); 63 63 } 64 64 const membership = await PaidPatreon.verifyPatron(r.site.id, code, baseUrl(req) + '/paid/callback').catch(() => null); … … 67 67 if (!active || cents < payload.cents) { 68 68 return renderPage(req, res, 'pages/paid-result', { 69 pageTitleKey: 'pres.t', bodyClass: 'on- special', ok: false,69 pageTitleKey: 'pres.t', bodyClass: 'on-post', ok: false, 70 70 reason: active ? 'tier' : 'notpatron', neededCents: payload.cents, haveCents: cents, postSlug: payload.post, patronUrl, 71 71 }); … … 76 76 const blob = signBlob({ purpose: 'reg', siteId: r.site.id, cents, challenge: options.challenge }, 900); 77 77 renderPage(req, res, 'pages/paid-passkey', { 78 pageTitleKey: 'ppk.t', bodyClass: 'on- special',78 pageTitleKey: 'ppk.t', bodyClass: 'on-post', 79 79 optionsJson: JSON.stringify(options), regBlob: blob, postSlug: payload.post, 80 80 });
Note:
See TracChangeset
for help on using the changeset viewer.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)