Stop using enum type as notification object, since that won’t work.

This commit is contained in:
Brent Simmons committed 2026-10-26 14:31:16 -07:00
1 parent 53adcc286e
commit 47ef9bc51c
3 files changed
+3 -3

No files matched your search

+1 -1
View File
@@ -114,7 +114,7 @@ enum AppDefaults {
}
set {
UserDefaults.standard.set(newValue.rawValue, forKey: Key.unreadCountDisplay)
NotificationCenter.default.post(name: .unreadCountDisplaySettingDidChange, object: self)
NotificationCenter.default.post(name: .unreadCountDisplaySettingDidChange, object: nil)
}
}
+1 -1
View File
@@ -78,7 +78,7 @@ extension AppDefaults {
}
set {
UserDefaults.standard.set(newValue.rawValue, forKey: Key.userInterfaceColorPalette)
NotificationCenter.default.post(name: .userInterfaceColorPaletteDidUpdate, object: self)
NotificationCenter.default.post(name: .userInterfaceColorPaletteDidUpdate, object: nil)
}
}
+1 -1
View File
@@ -49,7 +49,7 @@ final class SceneDelegate: UIResponder, UIWindowSceneDelegate {
updateUserInterfaceStyle()
NotificationCenter.default.addObserver(self, selector: #selector(handleUserInterfaceColorPaletteDidUpdate(_:)), name: .userInterfaceColorPaletteDidUpdate, object: AppDefaults.self)
NotificationCenter.default.addObserver(self, selector: #selector(handleUserInterfaceColorPaletteDidUpdate(_:)), name: .userInterfaceColorPaletteDidUpdate, object: nil)
if connectionOptions.urlContexts.first?.url != nil {
self.scene(scene, openURLContexts: connectionOptions.urlContexts)