From 91487434c03591896de97f3c9e281cda336689cc Mon Sep 17 00:00:00 2001 From: Jason Monk Date: Thu, 3 Dec 2015 11:08:10 -0500 Subject: [PATCH] Guard against no payment app Bug: 25990521 Change-Id: I3307fb197d1a38ff759628bf72f6b7e4afcb8001 --- src/com/android/settings/nfc/PaymentSettings.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/com/android/settings/nfc/PaymentSettings.java b/src/com/android/settings/nfc/PaymentSettings.java index 42545b909f5..985a1e698ae 100644 --- a/src/com/android/settings/nfc/PaymentSettings.java +++ b/src/com/android/settings/nfc/PaymentSettings.java @@ -115,8 +115,10 @@ public class PaymentSettings extends SettingsPreferenceFragment { PaymentBackend paymentBackend = new PaymentBackend(mContext); paymentBackend.refresh(); PaymentAppInfo app = paymentBackend.getDefaultApp(); - mSummaryLoader.setSummary(this, mContext.getString(R.string.payment_summary, - app.label)); + if (app != null) { + mSummaryLoader.setSummary(this, mContext.getString(R.string.payment_summary, + app.label)); + } } } }