From 172f4c8807d44ebe38c7f227b7fdc2d6a9dbe323 Mon Sep 17 00:00:00 2001 From: Ruben Beltran del Rio Date: Sat, 9 Mar 2024 14:17:34 +0100 Subject: Allow sync up and down --- src/command/remove_remote.rs | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'src/command/remove_remote.rs') diff --git a/src/command/remove_remote.rs b/src/command/remove_remote.rs index b2f554c..7590487 100644 --- a/src/command/remove_remote.rs +++ b/src/command/remove_remote.rs @@ -1,6 +1,6 @@ -use std::fs::remove_file; use std::io::Result; use crate::configuration::Configuration; +use crate::remote::remove; pub struct RemoveRemote; @@ -16,10 +16,7 @@ impl super::Command for RemoveRemote { } fn execute(&self, _: Option<&String>, configuration: &Configuration, _: &String) -> Result<()> { - if configuration.remote_config.exists() { - remove_file(&configuration.remote_config)?; - } - return Ok(()) + remove(&configuration.remote_config) } fn after_dependencies(&self) -> Vec> { -- cgit