summaryrefslogtreecommitdiffhomepage
path: root/mullvad-management-interface/src
diff options
context:
space:
mode:
authorMarkus Pettersson <markus.pettersson@mullvad.net>2023-09-27 09:39:44 +0200
committerDavid Lönnhager <david.l@mullvad.net>2023-10-09 14:40:15 +0200
commit998fd39aaebc1435065f1f4886f4bd40f5889e5a (patch)
treeaf2816f531a38a65e494d0376001eff7666756f2 /mullvad-management-interface/src
parent189c8d0273c036681142f73dfe3a5c619a0e0d28 (diff)
downloadmullvadvpn-998fd39aaebc1435065f1f4886f4bd40f5889e5a.tar.xz
mullvadvpn-998fd39aaebc1435065f1f4886f4bd40f5889e5a.zip
Code cleanup
- Get rid of extraneous calls to `clone` - Address nit: combine similar match arms into a single match arm - Fix `clippy` lint "unused `async` for function with no await statements" - Fix protobuf field numbers should start from 1 - This was not the case for `Socks5Local` & `Shadowsocks` - Refactor code for opening proxy connections - Cut down on duplicated code for setting up a proxied connection in `mullvad-api`. The difference between different connection modes is how they wrap the underlying `TCP` stream. - Remove `enable_access_method` & `disable_access_method` from RPC-client
Diffstat (limited to 'mullvad-management-interface/src')
-rw-r--r--mullvad-management-interface/src/client.rs18
1 files changed, 0 insertions, 18 deletions
diff --git a/mullvad-management-interface/src/client.rs b/mullvad-management-interface/src/client.rs
index 9e1b3772db..a4d56dd445 100644
--- a/mullvad-management-interface/src/client.rs
+++ b/mullvad-management-interface/src/client.rs
@@ -519,24 +519,6 @@ impl MullvadProxyClient {
.map(drop)
}
- pub async fn enable_access_method(
- &mut self,
- api_access_method_id: access_method::Id,
- ) -> Result<()> {
- let mut new_api_access_method = self.get_api_access_method(&api_access_method_id).await?;
- new_api_access_method.enable();
- self.update_access_method(new_api_access_method).await
- }
-
- pub async fn disable_access_method(
- &mut self,
- api_access_method_id: access_method::Id,
- ) -> Result<()> {
- let mut new_api_access_method = self.get_api_access_method(&api_access_method_id).await?;
- new_api_access_method.disable();
- self.update_access_method(new_api_access_method).await
- }
-
pub async fn remove_access_method(
&mut self,
api_access_method: access_method::Id,