diff --git a/packages/SystemUI/src/com/android/systemui/BatteryMeterView.java b/packages/SystemUI/src/com/android/systemui/BatteryMeterView.java index 1765627998383..cd53a34fbbc2b 100644 --- a/packages/SystemUI/src/com/android/systemui/BatteryMeterView.java +++ b/packages/SystemUI/src/com/android/systemui/BatteryMeterView.java @@ -326,6 +326,9 @@ public class BatteryMeterView extends LinearLayout implements if (mBatteryPercentView != null) { if (mShowPercentMode == MODE_ESTIMATE && !mCharging) { mBatteryController.getEstimatedTimeRemainingString((String estimate) -> { + if (mBatteryPercentView == null) { + return; + } if (estimate != null) { mBatteryPercentView.setText(estimate); setContentDescription(getContext().getString(