@@ -109,7 +109,9 @@ private PendingIntent toScheduleNotificationIntent(Bundle bundle) {
109109 notificationIntent .putExtra (RNPushNotificationPublisher .NOTIFICATION_ID , notificationID );
110110 notificationIntent .putExtras (bundle );
111111
112- return PendingIntent .getBroadcast (context , notificationID , notificationIntent , Build .VERSION .SDK_INT >= Build .VERSION_CODES .M ? PendingIntent .FLAG_UPDATE_CURRENT | PendingIntent .FLAG_IMMUTABLE : PendingIntent .FLAG_UPDATE_CURRENT );
112+ int flags = Build .VERSION .SDK_INT >= Build .VERSION_CODES .M ? PendingIntent .FLAG_UPDATE_CURRENT | PendingIntent .FLAG_IMMUTABLE : PendingIntent .FLAG_UPDATE_CURRENT ;
113+
114+ return PendingIntent .getBroadcast (context , notificationID , notificationIntent , flags );
113115 } catch (Exception e ) {
114116 Log .e (LOG_TAG , "Unable to parse Notification ID" , e );
115117 }
@@ -531,8 +533,10 @@ public void sendToNotificationCentreWithPicture(Bundle bundle, Bitmap largeIconB
531533 intent .putExtra ("message_id" , messageId );
532534 }
533535
534- PendingIntent pendingActionIntent = PendingIntent .getBroadcast (context , notificationID , actionIntent ,
535- PendingIntent .FLAG_UPDATE_CURRENT );
536+ int flags = Build .VERSION .SDK_INT >= Build .VERSION_CODES .M ? PendingIntent .FLAG_UPDATE_CURRENT | PendingIntent .FLAG_IMMUTABLE : PendingIntent .FLAG_UPDATE_CURRENT ;
537+
538+ PendingIntent pendingActionIntent = PendingIntent .getBroadcast (context , notificationID , actionIntent , flags );
539+
536540 if (action .equals ("ReplyInput" )){
537541 //Action with inline reply
538542 if (android .os .Build .VERSION .SDK_INT >= android .os .Build .VERSION_CODES .KITKAT_WATCH ){
0 commit comments