diff --git a/src/managers/commit_manager.rs b/src/managers/commit_manager.rs index 22e3f4e..3eb3709 100644 --- a/src/managers/commit_manager.rs +++ b/src/managers/commit_manager.rs @@ -182,7 +182,6 @@ impl CommitManager { apis: vec![models::api::Api::default(), models::api::Api::default()], ica_act: self.ica_action.clone(), }; - // parsers::api_parser::APIType prsr.parse_api(parsers::api_parser::APIType::Main); prsr.parse_api(parsers::api_parser::APIType::Auth); diff --git a/src/parsers/api_parser.rs b/src/parsers/api_parser.rs index 230df46..61b86dc 100644 --- a/src/parsers/api_parser.rs +++ b/src/parsers/api_parser.rs @@ -35,7 +35,7 @@ impl APIParser { if value.chars().nth(value.len() - 1) == Some('/') { self.apis[0].url = value; } else { - self.apis[0].url = value + "/"; + self.apis[0].url = format!("{value}/"); } break; } @@ -45,7 +45,7 @@ impl APIParser { if value.chars().nth(value.len() - 1) == Some('/') { self.apis[1].url = value; } else { - self.apis[1].url = value + "/"; + self.apis[1].url = format!("{value}/"); } break; } @@ -53,8 +53,8 @@ impl APIParser { } } - // for api in self.apis { - // } - // self.api.version = String::from(API_VERSION); + for api in &mut self.apis { + api.version = String::from(API_VERSION); + } } }