You've already forked Magisk
mirror of
https://github.com/topjohnwu/Magisk.git
synced 2025-09-06 06:36:58 +00:00
Use viewModelScope instead of GlobalScope
This commit is contained in:
@@ -125,10 +125,12 @@ class SuRequestViewModel(
|
||||
|
||||
val pos = selectedItemPosition
|
||||
timeoutPrefs.edit().putInt(handler.policy.packageName, pos).apply()
|
||||
handler.respond(action, Config.Value.TIMEOUT_LIST[pos])
|
||||
|
||||
// Kill activity after response
|
||||
DieEvent().publish()
|
||||
viewModelScope.launch {
|
||||
handler.respond(action, Config.Value.TIMEOUT_LIST[pos])
|
||||
// Kill activity after response
|
||||
DieEvent().publish()
|
||||
}
|
||||
}
|
||||
|
||||
private fun cancelTimer() {
|
||||
|
||||
Reference in New Issue
Block a user