From 800ba8825db3c92f20449315fe03490360ff2cf8 Mon Sep 17 00:00:00 2001 From: Johannes Marbach Date: Wed, 21 Jun 2023 09:28:35 +0200 Subject: [PATCH] Ignore push rules with unknown condition kinds Fixes: vector-im/element-ios#7601 --- MatrixSDK/NotificationCenter/MXNotificationCenter.m | 1 + changelog.d/7601.bugfix | 1 + 2 files changed, 2 insertions(+) create mode 100644 changelog.d/7601.bugfix diff --git a/MatrixSDK/NotificationCenter/MXNotificationCenter.m b/MatrixSDK/NotificationCenter/MXNotificationCenter.m index d153739827..d449ed0325 100644 --- a/MatrixSDK/NotificationCenter/MXNotificationCenter.m +++ b/MatrixSDK/NotificationCenter/MXNotificationCenter.m @@ -207,6 +207,7 @@ - (MXPushRule *)ruleMatchingEvent:(MXEvent *)event roomState:(MXRoomState*)roomS { MXLogDebug(@"[MXNotificationCenter] Warning: There is no MXPushRuleConditionChecker to check condition of kind: %@", condition.kind); conditionsOk = NO; + break; // Don't go further as we cannot guarantee that this rule matches } } break; diff --git a/changelog.d/7601.bugfix b/changelog.d/7601.bugfix new file mode 100644 index 0000000000..512b9be99e --- /dev/null +++ b/changelog.d/7601.bugfix @@ -0,0 +1 @@ +Ignore push rules with unknown condition kinds