Changeset dd856db in Klonkt for src/services/SettingsService.js


Ignore:
Timestamp:
06/24/2026 05:23:33 PM (3 months ago)
Author:
Robin Genis <roboburr@…>
Branches:
main
Children:
48ca5fc
Parents:
34076d7
Message:

Remove hub mode (step 1/2): keystone coercion + drop hub UI

getTenancy() now only returns 'solo'|'circle' (legacy 'hub' -> 'solo'), so every
tenancy==='hub' branch is unreachable. Removed the Hub tenancy radio + hub-home
branding form from settings, and the dead hub premium gate. Solo + Circle paths
unchanged. Dead hub code (hub.js, artists.js, hub-home view, /user routing, etc.)
gets deleted in step 2.

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

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/services/SettingsService.js

    r34076d7 rdd856db  
    11// Global app settings (key/value, cached). Primarily used for the tenancy mode.
    22//
    3 //   tenancy = 'solo'  -> exactly one site (the primary/owner site)
    4 //   tenancy = 'hub'   -> main site (company) + /user/, admin assigns Klonkt sites
     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.
    510//
    611// The cache is updated immediately on setSetting, so a toggle in admin
     
    3641export function getTenancy() {
    3742  const v = getSetting('tenancy', 'solo');
    38   return v === 'hub' ? 'hub' : v === 'circle' ? 'circle' : 'solo';
     43  // 'hub' is removed → coerce legacy values to 'solo'.
     44  return v === 'circle' ? 'circle' : 'solo';
    3945}
    4046
    4147export function setTenancy(mode) {
    42   const m = (mode === 'hub' || mode === 'circle') ? mode : 'solo';
     48  const m = mode === 'circle' ? 'circle' : 'solo';
    4349  setSetting('tenancy', m);
    4450}
Note: See TracChangeset for help on using the changeset viewer.