Skip to content
This repository has been archived by the owner on Jul 7, 2024. It is now read-only.

fix: only show launch button if install is successful #63

Merged
merged 1 commit into from
Jan 15, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,11 @@ class InstallerScreen(
if (viewModel.isFinished) {
Spacer(modifier = Modifier.height(16.dp))

viewModel.installManager.current?.let {
// Show launch only if success
val installSuccessful = viewModel.currentStep
?.let(viewModel.steps::get)
?.status == InstallerViewModel.InstallStatus.SUCCESSFUL
if (installSuccessful) {
Button(
onClick = { viewModel.launchVendetta() },
modifier = Modifier.fillMaxWidth()
Expand Down