mirror of
https://github.com/topjohnwu/Magisk.git
synced 2024-12-25 12:57:39 +00:00
Fixed leaking base instance to the event listener
This commit is contained in:
parent
36e4ccd800
commit
147264822c
@ -7,10 +7,6 @@ import timber.log.Timber
|
||||
|
||||
abstract class MagiskViewModel : LoadingViewModel(), Event.AutoListener {
|
||||
|
||||
init {
|
||||
Event.register(this)
|
||||
}
|
||||
|
||||
override fun onEvent(event: Int) = Timber.i("Event of $event was not handled")
|
||||
override fun getListeningEvents(): IntArray = intArrayOf()
|
||||
|
||||
|
@ -69,6 +69,7 @@ class HomeViewModel(
|
||||
private val latest = resources.getString(R.string.latest_version)
|
||||
|
||||
init {
|
||||
Event.register(this)
|
||||
refresh()
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user