Hi there, as doc says, disposable is not usually ...
# rx
l
Hi there, as doc says, disposable is not usually disposed by itself, so I need to dispose it manually in android lifecycle (in my case). Therefore I have necessity to make disposable global variable and put
if (disposable != null) dispose()
in every onDestroy(). How to facilitate this process?
m
aside from the actual way of handling this, this is kotlin so you can call
disposable?.dispose()
instead
👍 3