summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorTobias Järvelöv <tobias.jarvelov@mullvad.net>2025-04-29 16:37:51 +0200
committerSebastian Holmin <sebastian.holmin@mullvad.net>2025-05-28 13:25:32 +0200
commita301ebd0d46bfc8d6393d12af563c99713c2cf54 (patch)
treec130a8d028b252143d69a9887893f5f5d559c532
parent1e6ab7ab38eba6865ed5a175a32447fda18a2912 (diff)
downloadmullvadvpn-a301ebd0d46bfc8d6393d12af563c99713c2cf54.tar.xz
mullvadvpn-a301ebd0d46bfc8d6393d12af563c99713c2cf54.zip
Use new values for AppUpgrade event
To flag whether the installer is started manually or automatically
-rw-r--r--desktop/packages/mullvad-vpn/src/renderer/app.tsx15
1 files changed, 9 insertions, 6 deletions
diff --git a/desktop/packages/mullvad-vpn/src/renderer/app.tsx b/desktop/packages/mullvad-vpn/src/renderer/app.tsx
index 80dae05878..469650cec0 100644
--- a/desktop/packages/mullvad-vpn/src/renderer/app.tsx
+++ b/desktop/packages/mullvad-vpn/src/renderer/app.tsx
@@ -434,10 +434,8 @@ export default class AppRenderer {
// Ensure we have a the path to the verified installer and that we are not already trying
// to start the installer.
if (hasVerifiedInstallerPath) {
- // Ensure we don't try to start the installer multiple times by setting the status
- // as starting
this.reduxActions.appUpgrade.setAppUpgradeEvent({
- type: 'APP_UPGRADE_STATUS_STARTING_INSTALLER',
+ type: 'APP_UPGRADE_STATUS_MANUAL_STARTING_INSTALLER',
});
this.reduxActions.appUpgrade.resetAppUpgradeError();
@@ -670,10 +668,15 @@ export default class AppRenderer {
) {
// Only trigger the installer if the window is focused
if (windowFocused) {
- this.appUpgradeInstallerStart();
+ this.reduxActions.appUpgrade.setAppUpgradeEvent({
+ type: 'APP_UPGRADE_STATUS_AUTOMATIC_STARTING_INSTALLER',
+ });
+ IpcRendererEventChannel.app.upgradeInstallerStart(verifiedInstallerPath);
} else {
- // Otherwise, flag this as a failed automatic start (even though we haven't really attempted a start)
- this.reduxActions.appUpgrade.setAppUpgradeError('START_INSTALLER_AUTOMATIC_FAILED');
+ // Otherwise, flag this as requiring manual start
+ this.reduxActions.appUpgrade.setAppUpgradeEvent({
+ type: 'APP_UPGRADE_STATUS_MANUAL_START_INSTALLER',
+ });
}
}
}