Be able to accept multiple domains.
[gandi_dns_update.git] / src / config.rs
index e3b1309..fb6b7cf 100644 (file)
@@ -8,14 +8,13 @@ use crate::error::Result;
 pub struct Config {\r
     pub delay_between_check: time::Duration,\r
     pub api_key: String,\r
-    pub fqdn: String,\r
-    pub domains: Vec<String>,\r
+    pub domains: Vec<(String, String)>, // Hostname, domain.\r
     pub ttl: i32\r
 }\r
 \r
 impl Config {\r
     pub fn default() -> Self {\r
-        Config { delay_between_check: time::Duration::from_secs(120), api_key: String::from(""), fqdn: String::from(""), domains: Vec::new(), ttl: 300 }\r
+        Config { delay_between_check: time::Duration::from_secs(120), api_key: String::from(""), domains: Vec::new(), ttl: 300 }\r
     }\r
 \r
     pub fn read(file_path: &str) -> Result<Config> {\r