From 688c5c900d0558cd03ab6048f5c1183ba28aa7c8 Mon Sep 17 00:00:00 2001 From: Julia Reynolds Date: Fri, 13 May 2022 13:22:06 -0400 Subject: [PATCH] Update the 'is valid contentIntent' check Existing check required that the original request code be 0, but that's not actually required for the intent to work on this page Test: tap on email notification in history, be brought to email page and not main email list page Fixes: 232495202 Change-Id: I120022535ddbde19003f2db6f1b81a983d00789d --- .../notification/history/NotificationSbnViewHolder.java | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/com/android/settings/notification/history/NotificationSbnViewHolder.java b/src/com/android/settings/notification/history/NotificationSbnViewHolder.java index 166ee5d4ffc..1a703eb11fb 100644 --- a/src/com/android/settings/notification/history/NotificationSbnViewHolder.java +++ b/src/com/android/settings/notification/history/NotificationSbnViewHolder.java @@ -98,9 +98,7 @@ public class NotificationSbnViewHolder extends RecyclerView.ViewHolder { boolean isSnoozed, UiEventLogger uiEventLogger) { Intent appIntent = itemView.getContext().getPackageManager() .getLaunchIntentForPackage(pkg); - boolean isPendingIntentValid = pi != null && PendingIntent.getActivity( - itemView.getContext(), 0, pi.getIntent(), - PendingIntent.FLAG_IMMUTABLE | PendingIntent.FLAG_NO_CREATE) != null; + boolean isPendingIntentValid = pi != null && pi.isActivity(); if (isPendingIntentValid || appIntent != null) { itemView.setOnClickListener(v -> { uiEventLogger.logWithInstanceIdAndPosition(