summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAdam <56338480+adastx@users.noreply.github.com>2022-07-25 13:00:23 +0200
committerAdam <56338480+adastx@users.noreply.github.com>2022-07-25 13:00:23 +0200
commit510ceec33104f71591c03cfdbbba2a6911ec6ac4 (patch)
tree1eaf98a3ed9e2224c267c4e5ac5b18aaf42907e1
parent4b2c8ae92ea42ce2680af5658fa3311b50d6581c (diff)
Minor refactor
-rw-r--r--src/main.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/main.rs b/src/main.rs
index 02622f0..2bdb798 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -94,15 +94,15 @@ fn setup() -> (String, String) {
let city_id = read_file("city_id");
let api_key = read_file("api_key");
- let current_endpoint: String = format!(
+ let current_url: String = format!(
"https://api.openweathermap.org/data/2.5/weather?id={}&appid={}&units=metric",
city_id, api_key
);
- let forecast_endpoint: String = format!(
+ let forecast_url: String = format!(
"https://api.openweathermap.org/data/2.5/forecast?id={}&appid={}&units=metric&cnt=1",
city_id, api_key
);
- (current_endpoint, forecast_endpoint)
+ (current_url, forecast_url)
}
fn read_file(file_name: &str) -> String {