Changeset 72ec6a4 in Klonkt for src/services
- Timestamp:
- 07/31/2026 06:55:59 PM (6 weeks ago)
- Branches:
- main
- Children:
- 17546af
- Parents:
- bfa6fa1
- Location:
- src/services
- Files:
-
- 2 edited
-
ActivityPubService.js (modified) (2 diffs)
-
SettingsService.js (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
src/services/ActivityPubService.js
rbfa6fa1 r72ec6a4 26 26 import EmbedResolver from './EmbedResolver.js'; 27 27 import Push from './PushService.js'; 28 import { getTenancy } from './SettingsService.js';29 28 import { t as i18nT } from './i18n.js'; 30 29 import Blocklist from './BlocklistService.js'; … … 1418 1417 for (const cb of cbs) { try { cb(); } catch { /* a waiter must never break the rest */ } } 1419 1418 } 1420 // Hub-aware path prefix for a site's pages ('' in solo).1421 function pushPrefix(slug) { 1422 try { return getTenancy() === 'hub' ? `/user/${slug}` : ''; } catch { return ''; } 1423 }1419 // Path prefix for a site's pages. One instance is one owner, so the site 1420 // lives at the root; kept as a function because the push URLs read like 1421 // `${pushPrefix(slug)}/messages` all over this file. 1422 function pushPrefix() { return ''; } 1424 1423 // Notification language: the site's content language (fallback: instance default). 1425 1424 function pushLang(slug) { -
src/services/SettingsService.js
rbfa6fa1 r72ec6a4 1 // Global app settings (key/value, cached). Primarily used for the tenancy mode.1 // Global app settings (key/value, cached). 2 2 // 3 // tenancy = 'solo' -> exactly one site (the primary/owner site) 4 // tenancy = 'circle' -> solo site that federates with other solo Klonkt sites 5 // 6 // HUB MODE IS REMOVED (2026-06-24): multi-artist-per-domain was dropped in favour 7 // of solo + Cirkels. getTenancy() coerces any legacy 'hub' value to 'solo' so all 8 // the old `tenancy === 'hub'` branches are unreachable; the hub code is being 9 // deleted incrementally. 3 // One instance is one owner (Robins besluit, 31-7-2026). The old tenancy modes 4 // (hub = many artists on one domain, circle) are gone, code and all: the 5 // branches were already unreachable and have now been deleted. 10 6 // 11 7 // The cache is updated immediately on setSetting, so a toggle in admin … … 39 35 } 40 36 41 export function getTenancy() {42 // Tenancy is retired: 'hub' and 'circle' were both removed. Every site is43 // 'solo'. Cirkels are now an ActivityPub feature (auto-boost), not a mode.44 return 'solo';45 }46 47 export function setTenancy() {48 setSetting('tenancy', 'solo');49 }50 51 37 // ActivityPub / fediverse federation. ON by default. '0' = off: the site does 52 38 // not federate, /ap/* is gone, and the "from the fediverse" reactions disappear
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)