diff --git a/oAI/Services/SettingsService.swift b/oAI/Services/SettingsService.swift index 876ac0c..3f8088e 100644 --- a/oAI/Services/SettingsService.swift +++ b/oAI/Services/SettingsService.swift @@ -25,17 +25,11 @@ import Foundation import os import Security -/// Kill switch for the Personal Data tools (Calendar/Reminders/Contacts/Location & Maps). -/// Flip `isHiddenPendingAppleFix` back to `false` once Apple fixes the macOS 27 beta TCC bug -/// (filed with Apple). Each flag hides the relevant UI and forces the `*Enabled` getter to -/// return `false` regardless of the persisted DB value — no code deleted, just inert. +/// Kill switch for the entire Personal Data tools section (Calendar/Reminders/Contacts/ +/// Location & Maps). Hides the UI and forces every `*Enabled` getter to return `false` +/// regardless of the persisted DB value — no code deleted, just inert. enum PersonalDataTools { - /// Hides the entire Personal Data section. Flip to `false` once all four services work. static let isHiddenPendingAppleFix = false - /// Hides only the Contacts row. Was broken under hardened runtime on macOS 27 beta 2 - /// (Calendar/Reminders/Location were fine). Re-enabled 2026-07-21 to retest on beta 4 — - /// flip back to `true` if `CNContactStore.requestAccess` still fails under signed builds. - static let isContactsHiddenPendingAppleFix = false } @Observable @@ -719,7 +713,7 @@ class SettingsService { } var contactsEnabled: Bool { - get { !PersonalDataTools.isHiddenPendingAppleFix && !PersonalDataTools.isContactsHiddenPendingAppleFix && cache["contactsEnabled"] == "true" } + get { !PersonalDataTools.isHiddenPendingAppleFix && cache["contactsEnabled"] == "true" } set { cache["contactsEnabled"] = String(newValue) DatabaseService.shared.setSetting(key: "contactsEnabled", value: String(newValue)) diff --git a/oAI/Views/Screens/SettingsView.swift b/oAI/Views/Screens/SettingsView.swift index e09b691..0f3c8e7 100644 --- a/oAI/Views/Screens/SettingsView.swift +++ b/oAI/Views/Screens/SettingsView.swift @@ -829,10 +829,6 @@ It's better to admit "I need more information" or "I cannot do that" than to fak externalMCPSection // MARK: Personal Data - // isHiddenPendingAppleFix hides the entire section (macOS 27 beta TCC bug). - // isContactsHiddenPendingAppleFix hides just the Contacts row — was broken in beta 2 - // under hardened runtime while Calendar/Reminders/Location were fixed. Re-enabled - // 2026-07-21 to retest on beta 4; flip back to true if it regresses. if !PersonalDataTools.isHiddenPendingAppleFix { Divider() @@ -843,16 +839,6 @@ It's better to admit "I need more information" or "I cannot do that" than to fak .foregroundStyle(.teal) Text("Personal Data") .font(.system(size: 18, weight: .semibold)) - if PersonalDataTools.isContactsHiddenPendingAppleFix { - Text("β") - .font(.system(size: 11, weight: .bold)) - .foregroundStyle(.orange) - .padding(.horizontal, 5) - .padding(.vertical, 2) - .background(Color.orange.opacity(0.15)) - .clipShape(RoundedRectangle(cornerRadius: 4)) - .help("Beta Feature. May change.") - } } Text("Let the AI access your Calendar, Reminders, Contacts, and Location & Maps to answer questions about your schedule and surroundings. Each service is opt-in and uses standard macOS permission prompts. This functionality is in beta and may change.") .font(.system(size: 14)) @@ -889,16 +875,14 @@ It's better to admit "I need more information" or "I cannot do that" than to fak requestAccess: { remindersAccessState = await EventKitService.shared.requestReminderAccess() ? .granted : EventKitService.shared.reminderAccessState } ) rowDivider() - if !PersonalDataTools.isContactsHiddenPendingAppleFix { - personalDataRow( - title: "Contacts", - isEnabled: $settingsService.contactsEnabled, - state: contactsAccessState, - systemSettingsAnchor: "Privacy_Contacts", - requestAccess: { contactsAccessState = await ContactsService.shared.requestAccess() ? .granted : ContactsService.shared.accessState } - ) - rowDivider() - } + personalDataRow( + title: "Contacts", + isEnabled: $settingsService.contactsEnabled, + state: contactsAccessState, + systemSettingsAnchor: "Privacy_Contacts", + requestAccess: { contactsAccessState = await ContactsService.shared.requestAccess() ? .granted : ContactsService.shared.accessState } + ) + rowDivider() personalDataRow( title: "Location & Maps", isEnabled: $settingsService.locationMapsEnabled,