Fix crash from battery saver switch

Turns out most things expect the conditions to be loaded immediately
so if the dashboard hasn't been hit, they crash.  Instead load
immediately for everything but the dashboard.

Change-Id: Iaa1114c88b3766e2ac513acb417ef2a55a0f4e7f
Fixes: 28952354
This commit is contained in:
Jason Monk
2016-05-26 11:07:53 -04:00
parent eb02435cbf
commit e4d0ed502d
2 changed files with 13 additions and 4 deletions

View File

@@ -87,7 +87,7 @@ public class DashboardSummary extends InstrumentedFragment
mSummaryLoader = new SummaryLoader(getActivity(), categories);
setHasOptionsMenu(true);
Context context = getContext();
mConditionManager = ConditionManager.get(context);
mConditionManager = ConditionManager.get(context, false);
mSuggestionParser = new SuggestionParser(context,
context.getSharedPreferences(SUGGESTIONS, 0), R.xml.suggestion_ordering);
mSuggestionsChecks = new SuggestionsChecks(getContext());