Travis Griggs
01/11/2024, 8:12 PMYoussef Shoaib [MOD]
01/11/2024, 8:20 PMTravis Griggs
01/11/2024, 8:22 PMYoussef Shoaib [MOD]
01/11/2024, 8:25 PMlast
thing, you need to collect everything first. It is strange that firstOrNull
works thoughYoussef Shoaib [MOD]
01/11/2024, 8:26 PMfirstOrNull
is a terminal operatorTravis Griggs
01/11/2024, 8:27 PMYoussef Shoaib [MOD]
01/11/2024, 8:40 PMflow
given to you by the library is a shared one, and hence the terminal operator doesn't actually result in termination.Travis Griggs
01/11/2024, 8:42 PMDaniel Pitts
01/11/2024, 9:44 PMflow
in a way it's not actually intended. It sounds like this particular case you want to use MutableStateFlow.Travis Griggs
01/11/2024, 10:19 PMDaniel Pitts
01/11/2024, 10:20 PM