diff --git a/app/src/main/java/com/todoroo/astrid/activity/MainActivity.kt b/app/src/main/java/com/todoroo/astrid/activity/MainActivity.kt index d4b1ab173..200169849 100644 --- a/app/src/main/java/com/todoroo/astrid/activity/MainActivity.kt +++ b/app/src/main/java/com/todoroo/astrid/activity/MainActivity.kt @@ -390,7 +390,7 @@ class MainActivity : AppCompatActivity() { lifecycleScope.launch { val filter = intent.getFilter ?: intent.getFilterString?.let { defaultFilterProvider.getFilterFromPreference(it) } - ?: viewModel.state.value.filter + ?: defaultFilterProvider.getStartupFilter() val task = getTaskToLoad(filter) viewModel.setFilter(filter = filter, task = task) } diff --git a/app/src/main/java/com/todoroo/astrid/activity/MainActivityViewModel.kt b/app/src/main/java/com/todoroo/astrid/activity/MainActivityViewModel.kt index 76a1a57ac..62650f838 100644 --- a/app/src/main/java/com/todoroo/astrid/activity/MainActivityViewModel.kt +++ b/app/src/main/java/com/todoroo/astrid/activity/MainActivityViewModel.kt @@ -16,7 +16,6 @@ import com.todoroo.astrid.api.GtasksFilter import com.todoroo.astrid.api.TagFilter import com.todoroo.astrid.data.Task import dagger.hilt.android.lifecycle.HiltViewModel -import dagger.hilt.android.qualifiers.ApplicationContext import kotlinx.collections.immutable.ImmutableList import kotlinx.collections.immutable.persistentListOf import kotlinx.collections.immutable.toPersistentList @@ -46,7 +45,6 @@ import javax.inject.Inject @HiltViewModel class MainActivityViewModel @Inject constructor( savedStateHandle: SavedStateHandle, - @ApplicationContext context: Context, private val defaultFilterProvider: DefaultFilterProvider, private val filterProvider: FilterProvider, private val taskDao: TaskDao,