codelab-kotlin-coroutines
codelab-kotlin-coroutines copied to clipboard
fun getPlantsWithGrowZone attempts to return LiveData without a Type
trafficstars
https://codelabs.developers.google.com/codelabs/advanced-kotlin-coroutines/#5
In part 6. code given for PlantRepository.kt
fun getPlantsWithGrowZone(growZone: GrowZone) = liveData { etc.
should be
fun getPlantsWithGrowZone(growZone: GrowZone) = liveData<List<Plant> { etc.
Perhaps the type was supposed to be inferred, but Android Studio was having none of it.