mirror of
https://github.com/shadowsocks/ShadowsocksX-NG.git
synced 2026-11-11 22:25:05 +00:00
Migrate SilentLaunchStore from its versioned JSON file to the app's standard defaults domain (key `silentLaunch`), the platform's canonical home for GUI-scalar preferences, so the GUI preference category stops growing one file per item. Reads stay safe-side strict: a missing key or a value not bridgeable to Bool loads as not silent (plain bool(forKey:) would coerce "yes" to true). The file-form persistence-failure naming path is dropped — UserDefaults.set reports no failure — so SilentLaunchController keeps its persist-then-flip seam while errorMessage and its SettingsView presentation go away. The legacy file never shipped in any release; migrateLegacyFileIfPresent runs in the production composition root only, preserves the value on developer machines, and deletes the file (no-op when absent). The test composition uses a dedicated suite cleared at assembly; unit tests use per-test suites with removePersistentDomain teardown, never the standard domain. ADR-0017 carries a dated amendment (Status plus the affected consequence line); the settings.json separation rationale stands unchanged.