From f1adc9d91d7c977d7d03dffa94a35fb586a26b0e Mon Sep 17 00:00:00 2001 From: Ryan Zhao Date: Mon, 20 Dec 2021 12:25:05 +1100 Subject: [PATCH] fix incorrect incoming call issue --- .../NotificationServiceExtension.swift | 1 + 1 file changed, 1 insertion(+) diff --git a/SessionNotificationServiceExtension/NotificationServiceExtension.swift b/SessionNotificationServiceExtension/NotificationServiceExtension.swift index a0ff3f239..e67e6481b 100644 --- a/SessionNotificationServiceExtension/NotificationServiceExtension.swift +++ b/SessionNotificationServiceExtension/NotificationServiceExtension.swift @@ -92,6 +92,7 @@ public final class NotificationServiceExtension : UNNotificationServiceExtension } case let callMessage as CallMessage: MessageReceiver.handleCallMessage(callMessage, using: transaction) + guard case .preOffer = callMessage.kind else { return self.completeSilenty() } if !SSKPreferences.areCallsEnabled { if let sender = callMessage.sender, let thread = TSContactThread.fetch(for: sender, using: transaction), thread.hasOutgoingInteraction(with: transaction) { let infoMessage = TSInfoMessage.from(callMessage, associatedWith: thread)