mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-04 19:44:05 +00:00
Remove the dynamic member lookup from UserSettings in favour of nested access. (#6294)
* Remove the dynamic member lookup from UserSettings in favour of nested access. * Remove forwarding methods from UserSettings. * Update the Enterprise submodule.
This commit is contained in:
@@ -67,12 +67,12 @@ nonisolated struct NotificationToneManager: NotificationToneManagerProtocol {
|
||||
try? FileManager.default.removeItem(at: Self.selectedToneLocation)
|
||||
let toneLocation = Self.toneLocation(for: alertTone)
|
||||
try FileManager.default.copyItem(at: toneLocation, to: Self.selectedToneLocation)
|
||||
userSettings.selectedNotificationTone = alertTone
|
||||
userSettings.app.selectedNotificationTone = alertTone
|
||||
return Self.selectedToneLocation
|
||||
} catch {
|
||||
if (try? Self.selectedToneLocation.checkResourceIsReachable()) != true {
|
||||
// make sure the selected tone is reset if there's no custom tone present
|
||||
userSettings.selectedNotificationTone = nil
|
||||
userSettings.app.selectedNotificationTone = nil
|
||||
}
|
||||
throw error
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user