mirror of
https://gitlab.opencode.de/bwi/bundesmessenger/clients/bundesmessenger-ios.git
synced 2026-04-17 23:18:27 +02:00
Removed bug where notifications where discarded because of missing roomDisplayNames
This commit is contained in:
@@ -367,15 +367,15 @@ class NotificationService: UNNotificationServiceExtension {
|
|||||||
|
|
||||||
if localAuthenticationService.isProtectionSet {
|
if localAuthenticationService.isProtectionSet {
|
||||||
MXLog.debug("[NotificationService] preprocessPayload: Do not preprocess because app protection is set")
|
MXLog.debug("[NotificationService] preprocessPayload: Do not preprocess because app protection is set")
|
||||||
guard let roomDisplayName = roomSummary.displayName else {
|
|
||||||
throw NSEError.displayNameNotAvailable
|
|
||||||
}
|
|
||||||
|
|
||||||
// bwi: 5068 - hide content in message notifications
|
// bwi: 5068 - hide content in message notifications
|
||||||
if BWIBuildSettings.shared.bwiHideNotificationMessageBody {
|
if BWIBuildSettings.shared.bwiHideNotificationMessageBody {
|
||||||
// Hide the content
|
// Hide the content
|
||||||
bestAttemptContents[eventId]?.body = NotificationService.localizedString(forKey: "MESSAGE_PROTECTED")
|
bestAttemptContents[eventId]?.body = NotificationService.localizedString(forKey: "MESSAGE_PROTECTED")
|
||||||
} else {
|
} else {
|
||||||
|
guard let roomDisplayName = roomSummary.displayName else {
|
||||||
|
throw NSEError.displayNameNotAvailable
|
||||||
|
}
|
||||||
bestAttemptContents[eventId]?.title = roomDisplayName
|
bestAttemptContents[eventId]?.title = roomDisplayName
|
||||||
// At this stage we don't know the message type, so leave the body as set in didReceive.
|
// At this stage we don't know the message type, so leave the body as set in didReceive.
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user