From dc02ea91afbccf6baa221bcce5878d917210ab62 Mon Sep 17 00:00:00 2001 From: Markus Pettersson Date: Mon, 19 Jun 2023 10:55:26 +0200 Subject: [PATCH] Print the old account number even if device is revoked `mullvad account get` will print the old account number, even when the device has revoked. --- CHANGELOG.md | 2 ++ mullvad-cli/src/cmds/account.rs | 3 +++ 2 files changed, 5 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 18f27ae646d2..46019032db37 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -38,6 +38,8 @@ Line wrap the file at 100 chars. Th `mullvad tunnel ipv6 get`. - Update the CLI multihop settings to make it possible to set the entry location without toggling multihop on or off. +- In the CLI, the `mullvad account get` command will now print the account + number (if there is one) after the device has been revoked. #### Windows - In the CLI, add a unified `mullvad split-tunnel get` command to replace the old commands diff --git a/mullvad-cli/src/cmds/account.rs b/mullvad-cli/src/cmds/account.rs index 7faf0856e1b7..d0da9165fc55 100644 --- a/mullvad-cli/src/cmds/account.rs +++ b/mullvad-cli/src/cmds/account.rs @@ -127,6 +127,9 @@ impl Account { } DeviceState::Revoked => { println!("{REVOKED_MESSAGE}"); + if let Some(account_token) = rpc.get_account_history().await? { + println!("Mullvad account: {}", account_token); + } } }