manager: Fix reboot button is missing when flash

This commit is contained in:
weishu
2024-03-16 11:01:43 +08:00
parent e39be55db8
commit ca8a88f0cc

View File

@@ -207,12 +207,13 @@ fun installBoot(
val result = val result =
shell.newJob().add("${getKsuDaemonPath()} $cmd").to(stdoutCallback, stderrCallback) shell.newJob().add("${getKsuDaemonPath()} $cmd").to(stdoutCallback, stderrCallback)
.exec() .exec()
Log.i("KernelSU", "install boot $lkmUri result: $result") Log.i("KernelSU", "install boot $lkmUri result: ${result.isSuccess}")
lkmFile.delete() lkmFile.delete()
bootFile?.delete() bootFile?.delete()
onFinish(bootUri != null && result.isSuccess) // if boot uri is empty, it is direct install, when success, we should show reboot button
onFinish(bootUri == null && result.isSuccess)
return result.isSuccess return result.isSuccess
} }
} }