Properly initialize appComponent

This commit is contained in:
2016-08-03 22:13:30 -04:00
parent 8132188e46
commit 11378e07bf

View File

@@ -81,10 +81,11 @@ public abstract class BaseDialog extends AppCompatDialogFragment
HabitsApplication app =
(HabitsApplication) getContext().getApplicationContext();
prefs = app.getComponent().getPreferences();
habitList = app.getComponent().getHabitList();
commandRunner = app.getComponent().getCommandRunner();
modelFactory = app.getComponent().getModelFactory();
appComponent = app.getComponent();
prefs = appComponent.getPreferences();
habitList = appComponent.getHabitList();
commandRunner = appComponent.getCommandRunner();
modelFactory = appComponent.getModelFactory();
ButterKnife.bind(this, view);