Changeset fc40410 in Klonkt for src/routes/activitypub.js
- Timestamp:
- 07/28/2026 07:43:47 AM (6 weeks ago)
- Branches:
- main
- Children:
- b258a79
- Parents:
- 6bc2e31b
- File:
-
- 1 edited
-
src/routes/activitypub.js (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
src/routes/activitypub.js
r6bc2e31b rfc40410 145 145 if (!auth || auth.site.slug !== req.params.slug) return res.status(403).end(); 146 146 const base = baseUrl(req); 147 // Gated feature (FEP-633c): may this account see EXTERNAL embeds? A ward's 148 // world outside the fediverse is the guardians' call. The gate is applied 149 // here, at serialisation: a blocked embed is never sent, because an embed the 150 // client merely hides has still been delivered to the device. 151 const isWard = (() => { try { return Guardianship.listGuardians(auth.site.slug).length > 0; } catch { return false; } })(); 152 const embedsAllowed = Guardianship.externalEmbedsAllowed(auth.site.external_embeds, isWard); 147 153 const items = AP.getTimeline(auth.site.slug, 60).map((t) => ({ 148 154 id: `${t.id}#create`, … … 195 201 'shaer:liked': !!t.liked, 196 202 'shaer:boosted': !!t.boosted, 203 // An external (non-fediverse) embed, thumbnail-only and never an iframe. 204 // Omitted entirely when the gate is closed (see above). 205 'shaer:embed': embedsAllowed ? AP.timelineEmbed(t.embed_json) : undefined, 197 206 }, 198 207 }));
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)