Merge "added null check in doInBackground and if null, properly intializes variables." into nyc-dev

This commit is contained in:
Richard Ho
2016-06-15 21:06:05 +00:00
committed by Android (Google) Code Review

View File

@@ -307,6 +307,13 @@ public class SettingsDrawerActivity extends Activity {
return TileUtils.getCategories(SettingsDrawerActivity.this, sTileCache);
}
@Override
protected void onPreExecute() {
if (sConfigTracker == null || sTileCache == null) {
getDashboardCategories();
}
}
@Override
protected void onPostExecute(List<DashboardCategory> dashboardCategories) {
for (int i = 0; i < dashboardCategories.size(); i++) {