mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-02 12:07:55 +00:00
Add toggle not invite notifications. (#2207)
This commit is contained in:
@@ -141,6 +141,18 @@ final class NotificationSettingsProxy: NotificationSettingsProxyProtocol {
|
||||
await updatedSettings()
|
||||
}
|
||||
|
||||
func isInviteForMeEnabled() async throws -> Bool {
|
||||
try await notificationSettings.isInviteForMeEnabled()
|
||||
}
|
||||
|
||||
func setInviteForMeEnabled(enabled: Bool) async throws {
|
||||
let backgroundTask = await backgroundTaskService?.startBackgroundTask(withName: "setInviteForMeEnabled")
|
||||
defer { backgroundTask?.stop() }
|
||||
|
||||
try await notificationSettings.setInviteForMeEnabled(enabled: enabled)
|
||||
await updatedSettings()
|
||||
}
|
||||
|
||||
func getRoomsWithUserDefinedRules() async throws -> [String] {
|
||||
await notificationSettings.getRoomsWithUserDefinedRules(enabled: true)
|
||||
}
|
||||
|
||||
@@ -40,6 +40,8 @@ protocol NotificationSettingsProxyProtocol {
|
||||
func setUserMentionEnabled(enabled: Bool) async throws
|
||||
func isCallEnabled() async throws -> Bool
|
||||
func setCallEnabled(enabled: Bool) async throws
|
||||
func isInviteForMeEnabled() async throws -> Bool
|
||||
func setInviteForMeEnabled(enabled: Bool) async throws
|
||||
func getRoomsWithUserDefinedRules() async throws -> [String]
|
||||
func canHomeserverPushEncryptedEventsToDevice() async -> Bool
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user