diff --git a/app/src/main/java/com/topjohnwu/magisk/redesign/home/HomeViewModel.kt b/app/src/main/java/com/topjohnwu/magisk/redesign/home/HomeViewModel.kt index c244b3a3c..26adc56dd 100644 --- a/app/src/main/java/com/topjohnwu/magisk/redesign/home/HomeViewModel.kt +++ b/app/src/main/java/com/topjohnwu/magisk/redesign/home/HomeViewModel.kt @@ -140,15 +140,12 @@ class HomeViewModel( fun onManagerPressed() = ManagerInstallDialog().publish() fun onMagiskPressed() { - //pre-fix so user doesn't click twice accidentally - stateMagiskProgress.value = 1 - withPermissions( Manifest.permission.READ_EXTERNAL_STORAGE, Manifest.permission.WRITE_EXTERNAL_STORAGE - ).map { check(it);it }.subscribeK(onError = { - stateManagerProgress.value = 0 - }) { + ).map { check(it);it }.subscribeK { + //pre-fix so user doesn't click twice accidentally + stateMagiskProgress.value = 1 DownloadService(get()) { subject = Magisk(Configuration.Download) } diff --git a/app/src/main/res/layout/fragment_home_md2.xml b/app/src/main/res/layout/fragment_home_md2.xml index 918bd1074..7f795f294 100644 --- a/app/src/main/res/layout/fragment_home_md2.xml +++ b/app/src/main/res/layout/fragment_home_md2.xml @@ -118,7 +118,7 @@