diff --git a/core/CHANGELOG.md b/core/CHANGELOG.md index e5c230db6..c83d62dd6 100644 --- a/core/CHANGELOG.md +++ b/core/CHANGELOG.md @@ -6,6 +6,8 @@ **Bug Fixes** +* Fixes the issue where the system caches the extras from the previous intent for the PendingIntent and thus the extras passed to the PendingIntent for the new Intent would be ignored. + **New Features** **Breaking Changes** diff --git a/core/java/androidx/test/core/app/InstrumentationActivityInvoker.java b/core/java/androidx/test/core/app/InstrumentationActivityInvoker.java index dbaa81c6c..eb9af53f8 100644 --- a/core/java/androidx/test/core/app/InstrumentationActivityInvoker.java +++ b/core/java/androidx/test/core/app/InstrumentationActivityInvoker.java @@ -464,7 +464,7 @@ public void startActivityForResult(Intent intent, @Nullable Bundle activityOptio getApplicationContext(), /* requestCode= */ 0, intent, - /* flags= */ PendingIntent.FLAG_UPDATE_CURRENT | intentMutability)) + /* flags= */ PendingIntent.FLAG_CANCEL_CURRENT | intentMutability)) .putExtra(TARGET_ACTIVITY_OPTIONS_BUNDLE_KEY, activityOptionsBundle); getApplicationContext().startActivity(bootstrapIntent, activityOptionsBundle);