Skip to content

Commit

Permalink
Merge pull request JohanDegraeve#579 from paulplant/develop
Browse files Browse the repository at this point in the history
revert CNContactStore.authorizationStatus changes for Xcode15 building
  • Loading branch information
JohanDegraeve authored Oct 14, 2024
2 parents 8fee6f5 + 71243de commit b176bc9
Showing 1 changed file with 1 addition and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ class SettingsViewContactImageSettingsViewModel: SettingsViewModelProtocol {
case .notDetermined:
return .none

case .restricted, .limited:
case .restricted:
// by clicking row, show what it means to be restricted, according to Apple doc
return .disclosureIndicator

Expand Down Expand Up @@ -153,10 +153,6 @@ class SettingsViewContactImageSettingsViewModel: SettingsViewModelProtocol {
trace("in SettingsViewContactImageSettingsViewModel, CNContactStore access restricted, according to apple doc 'possibly due to active restrictions such as parental controls being in place'", log: self.log, category: ConstantsLog.categoryRootView, type: .error)
UserDefaults.standard.enableContactImage = false

case .limited:
trace("in SettingsViewContactImageSettingsViewModel, CNContactStore access limited, ask the user to give full access", log: self.log, category: ConstantsLog.categoryRootView, type: .error)
UserDefaults.standard.enableContactImage = false

case .denied:
trace("in SettingsViewContactImageSettingsViewModel, CNContactStore access denied by user", log: self.log, category: ConstantsLog.categoryRootView, type: .error)
UserDefaults.standard.enableContactImage = false
Expand Down Expand Up @@ -229,10 +225,6 @@ class SettingsViewContactImageSettingsViewModel: SettingsViewModelProtocol {
// by clicking row, show what it means to be restricted, according to Apple doc
return SettingsSelectedRowAction.showInfoText(title: Texts_Common.warning, message: Texts_SettingsView.infoContactsAccessRestricted)

case .limited:
// by clicking row, show what it means to be limited, according to Apple doc
return SettingsSelectedRowAction.showInfoText(title: Texts_Common.warning, message: Texts_SettingsView.infoContactsAccessLimited)

@unknown default:
trace("in SettingsViewContactImageSettingsViewModel, unknown case returned when authorizing CNContactStore ", log: self.log, category: ConstantsLog.categoryRootView, type: .error)

Expand Down

0 comments on commit b176bc9

Please sign in to comment.