From 4a12c136a058d622a65d5324739a3779eafbef81 Mon Sep 17 00:00:00 2001 From: Mark Qvist Date: Sat, 21 Sep 2024 20:59:50 +0200 Subject: [PATCH] Set immutable flag on notification intent. Closes #56. --- sbapp/services/sidebandservice.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sbapp/services/sidebandservice.py b/sbapp/services/sidebandservice.py index adc115b..c73e590 100644 --- a/sbapp/services/sidebandservice.py +++ b/sbapp/services/sidebandservice.py @@ -116,7 +116,7 @@ class SidebandService(): notification_intent.setFlags(Intent.FLAG_ACTIVITY_SINGLE_TOP) notification_intent.setAction(Intent.ACTION_MAIN) notification_intent.addCategory(Intent.CATEGORY_LAUNCHER) - self.notification_intent = PendingIntent.getActivity(self.app_context, 0, notification_intent, 0) + self.notification_intent = PendingIntent.getActivity(self.app_context, 0, notification_intent, PendingIntent.FLAG_IMMUTABLE) notification.setContentIntent(self.notification_intent) notification.setAutoCancel(True)