summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorOskar <oskar@mullvad.net>2025-10-08 15:02:06 +0200
committerOskar <oskar@mullvad.net>2025-10-09 13:21:11 +0200
commitce0ddc8db47eb50f0acb0c66394baf9393d8b8e7 (patch)
tree6778a83c59ab96b09c6bf3043fdb4413d47ab056
parentd7b9501d9e5e2c54e5f3552c1016b5c62f454be3 (diff)
downloadmullvadvpn-ce0ddc8db47eb50f0acb0c66394baf9393d8b8e7.tar.xz
mullvadvpn-ce0ddc8db47eb50f0acb0c66394baf9393d8b8e7.zip
Do not treat no expiry as not expired
-rw-r--r--desktop/packages/mullvad-vpn/src/renderer/redux/account/actions.ts4
-rw-r--r--desktop/packages/mullvad-vpn/src/renderer/redux/account/reducers.ts2
2 files changed, 3 insertions, 3 deletions
diff --git a/desktop/packages/mullvad-vpn/src/renderer/redux/account/actions.ts b/desktop/packages/mullvad-vpn/src/renderer/redux/account/actions.ts
index 98a689cd76..2dcd7f030d 100644
--- a/desktop/packages/mullvad-vpn/src/renderer/redux/account/actions.ts
+++ b/desktop/packages/mullvad-vpn/src/renderer/redux/account/actions.ts
@@ -70,7 +70,7 @@ interface IUpdateAccountHistoryAction {
interface IUpdateAccountExpiryAction {
type: 'UPDATE_ACCOUNT_EXPIRY';
expiry?: string;
- expired: boolean;
+ expired?: boolean;
}
interface IUpdateDevicesAction {
@@ -194,7 +194,7 @@ function updateAccountExpiry(expiry?: string): IUpdateAccountExpiryAction {
return {
type: 'UPDATE_ACCOUNT_EXPIRY',
expiry,
- expired: expiry !== undefined && hasExpired(expiry),
+ expired: expiry === undefined ? undefined : hasExpired(expiry),
};
}
diff --git a/desktop/packages/mullvad-vpn/src/renderer/redux/account/reducers.ts b/desktop/packages/mullvad-vpn/src/renderer/redux/account/reducers.ts
index 46b6117ae5..13e9fd5a2b 100644
--- a/desktop/packages/mullvad-vpn/src/renderer/redux/account/reducers.ts
+++ b/desktop/packages/mullvad-vpn/src/renderer/redux/account/reducers.ts
@@ -132,7 +132,7 @@ export default function (
status.expiredState = 'expired';
} else if (
status.expiredState === 'expired' &&
- !action.expired &&
+ action.expired === false &&
// If the system clock changes from something that makes the expiry out of time, backwards
// to something that is before the expiry, then the time added view shouldn't be displayed
// since the expiry hasn't changed.