Merge "Correct null UserHandle handling for ACTION_CHANGE_DEFAULT" into tm-dev am: 0469e3b5ba
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Settings/+/17180788 Change-Id: I2ac9a3f48928cb00f8a0674d489d2b5fd4eabc86
This commit is contained in:
@@ -59,10 +59,13 @@ public final class PaymentDefaultDialog extends AlertActivity implements
|
|||||||
CardEmulation.EXTRA_SERVICE_COMPONENT);
|
CardEmulation.EXTRA_SERVICE_COMPONENT);
|
||||||
String category = intent.getStringExtra(CardEmulation.EXTRA_CATEGORY);
|
String category = intent.getStringExtra(CardEmulation.EXTRA_CATEGORY);
|
||||||
UserHandle userHandle = intent.getParcelableExtra(Intent.EXTRA_USER);
|
UserHandle userHandle = intent.getParcelableExtra(Intent.EXTRA_USER);
|
||||||
|
|
||||||
|
int userId;
|
||||||
if (userHandle == null) {
|
if (userHandle == null) {
|
||||||
userHandle = UserHandle.CURRENT;
|
userId = UserHandle.myUserId();
|
||||||
|
} else {
|
||||||
|
userId = userHandle.getIdentifier();
|
||||||
}
|
}
|
||||||
int userId = userHandle.getIdentifier();
|
|
||||||
|
|
||||||
setResult(RESULT_CANCELED);
|
setResult(RESULT_CANCELED);
|
||||||
if (!buildDialog(component, category, userId)) {
|
if (!buildDialog(component, category, userId)) {
|
||||||
|
Reference in New Issue
Block a user