Category identifier for call invites

This commit is contained in:
ismailgulek 2020-08-10 18:17:46 +03:00
parent eec3bd9c01
commit b25c0710db
2 changed files with 5 additions and 0 deletions

View file

@ -19,5 +19,6 @@ import Foundation
enum Constants {
static let toBeRemovedNotificationCategoryIdentifier = "TO_BE_REMOVED"
static let callNotificationsCategoryIdentifier = "CALL"
}

View file

@ -543,6 +543,10 @@ class NotificationService: UNNotificationServiceExtension {
return nil
}
if event.eventType == .callInvite {
return Constants.callNotificationsCategoryIdentifier
}
guard event.eventType == .roomMessage || event.eventType == .roomEncrypted else {
return nil
}