diff --git a/lib/utils/background_push.dart b/lib/utils/background_push.dart index 533bedfac..f38f0dd26 100644 --- a/lib/utils/background_push.dart +++ b/lib/utils/background_push.dart @@ -448,6 +448,7 @@ class BackgroundPush { } Future _onUpMessage(PushMessage pushMessage, String i) async { + Logs().wtf('Push Notification from UP received', pushMessage); final message = pushMessage.content; upAction = true; final data = Map.from( @@ -461,6 +462,8 @@ class BackgroundPush { l10n: l10n, activeRoomId: matrix?.activeRoomId, flutterLocalNotificationsPlugin: _flutterLocalNotificationsPlugin, + useNotificationActions: + false, // Buggy with UP: https://codeberg.org/UnifiedPush/flutter-connector/issues/34 ); } } diff --git a/lib/utils/push_helper.dart b/lib/utils/push_helper.dart index 70f7a40f5..0aa60418f 100644 --- a/lib/utils/push_helper.dart +++ b/lib/utils/push_helper.dart @@ -26,6 +26,7 @@ Future pushHelper( L10n? l10n, String? activeRoomId, required FlutterLocalNotificationsPlugin flutterLocalNotificationsPlugin, + bool useNotificationActions = true, }) async { try { await _tryPushHelper( @@ -34,6 +35,7 @@ Future pushHelper( l10n: l10n, activeRoomId: activeRoomId, flutterLocalNotificationsPlugin: flutterLocalNotificationsPlugin, + useNotificationActions: useNotificationActions, ); } catch (e, s) { Logs().e('Push Helper has crashed! Writing into temporary file', e, s); @@ -69,6 +71,7 @@ Future _tryPushHelper( L10n? l10n, String? activeRoomId, required FlutterLocalNotificationsPlugin flutterLocalNotificationsPlugin, + bool useNotificationActions = true, }) async { final isBackgroundMessage = client == null; Logs().v( @@ -278,7 +281,7 @@ Future _tryPushHelper( importance: Importance.high, priority: Priority.max, groupKey: event.room.spaceParents.firstOrNull?.roomId ?? 'rooms', - actions: event.type == EventTypes.RoomMember + actions: event.type == EventTypes.RoomMember || !useNotificationActions ? null : [ AndroidNotificationAction(