mirror of
https://github.com/ReVanced/revanced-manager
synced 2026-04-25 17:15:36 +02:00
fix: Mount install (#3111)
This commit is contained in:
@@ -117,6 +117,8 @@ class RootInstaller(
|
||||
|
||||
execute("pm install -r -d --user 0 \"${stockApp.absolutePath}\"")
|
||||
.assertSuccess("Failed to install stock app")
|
||||
|
||||
stockApp.delete()
|
||||
}
|
||||
|
||||
remoteFS.getFile(modulePath).apply {
|
||||
|
||||
@@ -45,6 +45,7 @@ import app.revanced.manager.util.Options
|
||||
import app.revanced.manager.util.PM
|
||||
import app.revanced.manager.util.PatchSelection
|
||||
import app.revanced.manager.util.tag
|
||||
import com.topjohnwu.superuser.Shell
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
import kotlinx.coroutines.flow.first
|
||||
import kotlinx.coroutines.withContext
|
||||
@@ -265,7 +266,9 @@ class PatcherWorker(
|
||||
Result.failure()
|
||||
} finally {
|
||||
patchedApk.delete()
|
||||
if (args.input is SelectedApp.Local && args.input.temporary) {
|
||||
// Only delete the input APK right after patching finishes when the user isn't rooted, since it would be needed for mounting
|
||||
// (it would be deleted right after installing with root)
|
||||
if (args.input is SelectedApp.Local && args.input.temporary && Shell.isAppGrantedRoot() == false) {
|
||||
args.input.file.delete()
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user