Merge "Add null check when restart batteryinfo loader" into qt-dev

am: 285fc7f7c3

Change-Id: I75c8925d1b4b0707eb58de2e46f94c539e091e56
This commit is contained in:
Lei Yu
2019-05-08 13:50:37 -07:00
committed by android-build-merger
2 changed files with 15 additions and 0 deletions

View File

@@ -378,6 +378,9 @@ public class PowerUsageSummary extends PowerUsageBase implements OnLongClickList
@VisibleForTesting
void restartBatteryInfoLoader() {
if (getContext() == null) {
return;
}
getLoaderManager().restartLoader(BATTERY_INFO_LOADER, Bundle.EMPTY,
mBatteryInfoLoaderCallbacks);
if (mPowerFeatureProvider.isEstimateDebugEnabled()) {