diff --git a/app/src/main/java/com/topjohnwu/magisk/ui/superuser/SuperuserViewModel.kt b/app/src/main/java/com/topjohnwu/magisk/ui/superuser/SuperuserViewModel.kt index aa0bcfee4..a8fa02f18 100644 --- a/app/src/main/java/com/topjohnwu/magisk/ui/superuser/SuperuserViewModel.kt +++ b/app/src/main/java/com/topjohnwu/magisk/ui/superuser/SuperuserViewModel.kt @@ -42,6 +42,11 @@ class SuperuserViewModel( init { rxBus.register() + .filter { + val isIgnored = it.item == ignoreNext + if (isIgnored) ignoreNext = null + !isIgnored + } .subscribeK { togglePolicy(it.item, it.enable) } .add() rxBus.register()