Fix a crash when an app requests Bluetooth to be discoverable am: ebbfce0bf1

am: 4b27231fd4

Change-Id: Id383dca443a09dd25b520978b9fbe8f5791eb46f
This commit is contained in:
Jack He
2017-04-04 04:17:31 +00:00
committed by android-build-merger

View File

@@ -180,8 +180,8 @@ public class RequestPermissionActivity extends Activity implements
builder.setMessage(message);
} else {
CharSequence message = mAppLabel != null
? getString(R.string.bluetooth_ask_discovery, mAppLabel)
: getString(R.string.bluetooth_ask_discovery_no_name);
? getString(R.string.bluetooth_ask_discovery, mAppLabel, mTimeout)
: getString(R.string.bluetooth_ask_discovery_no_name, mTimeout);
builder.setMessage(message);
}
builder.setPositiveButton(getString(R.string.allow), this);