From 3a53ebefd1ccbf18b9d39b738867ae5a0b6d4c9e Mon Sep 17 00:00:00 2001 From: Brent Simmons Date: Thu, 19 Mar 2026 12:26:21 -0700 Subject: [PATCH] Update user defaults immediately on toggle switch for iCloud sync content setting. --- .../AccountInspectorViewController.swift | 7 ++++--- iOS/Inspector/Inspector.storyboard | 15 +++++++++------ 2 files changed, 13 insertions(+), 9 deletions(-) diff --git a/iOS/Inspector/AccountInspectorViewController.swift b/iOS/Inspector/AccountInspectorViewController.swift index bae61cf62..57639c02a 100644 --- a/iOS/Inspector/AccountInspectorViewController.swift +++ b/iOS/Inspector/AccountInspectorViewController.swift @@ -56,9 +56,10 @@ final class AccountInspectorViewController: UITableViewController { override func viewWillDisappear(_ animated: Bool) { account?.name = nameTextField.text account?.isActive = activeSwitch.isOn - if account?.type == .cloudKit { - UserDefaults.standard.set(syncContentSwitch.isOn, forKey: Account.iCloudSyncArticleContentForUnreadArticlesKey) - } + } + + @IBAction func syncContentSwitchDidChange(_ sender: UISwitch) { + UserDefaults.standard.set(sender.isOn, forKey: Account.iCloudSyncArticleContentForUnreadArticlesKey) } @objc func done() { diff --git a/iOS/Inspector/Inspector.storyboard b/iOS/Inspector/Inspector.storyboard index 95cffca4a..e88729b20 100644 --- a/iOS/Inspector/Inspector.storyboard +++ b/iOS/Inspector/Inspector.storyboard @@ -1,8 +1,8 @@ - + - + @@ -16,7 +16,7 @@ - +