Commit 3ff8873b authored by Julia Reynolds's avatar Julia Reynolds Committed by The Android Automerger

Fix crash adding an account.

Bug: 27709695
Change-Id: I66b69d71ed346e8d6f0d8493e6dd415d81f41ac1
parent 65e9cdf2
......@@ -137,17 +137,12 @@ public abstract class ConfirmDeviceCredentialBaseFragment extends InstrumentedFr
if (intent != null) {
CharSequence titleText = intent.getCharSequenceExtra(
ConfirmDeviceCredentialBaseFragment.TITLE_TEXT);
if (titleText == null && supplementalText == null) {
if (titleText == null || suplementalText == null) {
return;
}
StringBuilder builder = new StringBuilder();
if (titleText != null) {
builder.append(titleText).append(",");
}
if (supplementalText != null) {
builder.append(supplementalText);
}
getActivity().setTitle(Utils.createAccessibleSequence(titleText, builder.toString()));
String accessibilityTitle =
new StringBuilder(titleText).append(",").append(suplementalText).toString();
getActivity().setTitle(Utils.createAccessibleSequence(titleText, accessibilityTitle));
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment