I'm using a Flow just to communicate from the ViewModel with an activity, but I dont really need to pass any parameter to the activity. I just need the activity to react to the call.
Right now I have a flow of a nullable type:
val myFlow: Flow<Nothing?> = someChannel.receiveAsFlow()
And I need to emit a null, since Nothing cannot be instantiated:
someChannel.send(null)
What I'd like to do:
val myFlow: Flow<Nothing>
and then:
someChannel.send()
But of course that doesn't compile.
Is there a better way of doing this?