Changeset 283f618 in Klonkt for src/middleware


Ignore:
Timestamp:
06/26/2026 07:26:26 AM (2 months ago)
Author:
Robin Genis <roboburr@…>
Branches:
main
Children:
f278df9
Parents:
eb2fe08
Message:

feat(fediverse): add an ActivityPub on/off toggle (off = no federation, no comments)

A solo site can now run without the fediverse. ap_enabled (default on, Beheer ->
Instellingen). When off: /ap/*, WebFinger and NodeInfo 404 (undiscoverable), the
'from the fediverse' reactions section is hidden on posts (= no comments, since
native comments were removed), the profile follow button and the fediverse admin
links disappear. Cirkels is separate (not gated here).

Co-Authored-By: Claude <noreply@…>

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/middleware/render.js

    reb2fe08 r283f618  
    1717import PermissionsService from '../services/PermissionsService.js';
    1818import { isViewer } from './auth.js';
    19 import { getSetting } from '../services/SettingsService.js';
     19import { getSetting, apEnabled } from '../services/SettingsService.js';
    2020import { isPremium as isPremiumInstance, premiumEnabled, premiumUnlocked } from '../services/PatreonService.js';
    2121import ActivityPubService from '../services/ActivityPubService.js';
     
    122122    canSeeBeheer,
    123123    canManageFedi,
     124    apEnabled: apEnabled(),
    124125    isViewer: _isViewer,
    125126    canMutate: !_isViewer,
Note: See TracChangeset for help on using the changeset viewer.