From 7d00d6f8636439f574c35b2a8aa2a124bfd28475 Mon Sep 17 00:00:00 2001 From: Adam Cooper Date: Mon, 21 Mar 2022 09:30:43 -0400 Subject: [PATCH] Remove hard-coded username instances (#9) --- src/main.rs | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/main.rs b/src/main.rs index 9fe22af..9bc8584 100644 --- a/src/main.rs +++ b/src/main.rs @@ -141,7 +141,7 @@ async fn get_folder_contents(url_tail: &str, config: &Config) -> Result Result Result> { +async fn publicise_it(path: &str, config: &Config) -> Result> { debug!("[publicise_it] Entering function..."); let url = "https://cloud.theadamcooper.com/ocs/v2.php/apps/files_sharing/api/v1/shares"; let method = reqwest::Method::POST; @@ -161,7 +161,7 @@ async fn publicise_it(path: &str, password: &str) -> Result Result std::io::Result<()> { } debug!("[main] {:?}", &config); let full_path = &(String::from("/remote.php/dav/files/") + &config.credentials.username + "/" + &config.paths.target); - let folder_contents: String = + let folder_contents: String = get_folder_contents(full_path, &config) .await .unwrap();