neon_arch commited on
Commit
6d3396b
1 Parent(s): d3007e3

✨ feat: provide functionality to parse the new config option

Browse files
Files changed (1) hide show
  1. src/config/parser.rs +2 -0
src/config/parser.rs CHANGED
@@ -32,6 +32,7 @@ pub struct Config {
32
  pub logging: bool,
33
  pub debug: bool,
34
  pub upstream_search_engines: Vec<String>,
 
35
  }
36
 
37
  /// Configuration options for the aggregator.
@@ -80,6 +81,7 @@ impl Config {
80
  .into_iter()
81
  .filter_map(|(key, value)| value.then_some(key))
82
  .collect(),
 
83
  })
84
  })
85
  }
 
32
  pub logging: bool,
33
  pub debug: bool,
34
  pub upstream_search_engines: Vec<String>,
35
+ pub request_timeout: u8,
36
  }
37
 
38
  /// Configuration options for the aggregator.
 
81
  .into_iter()
82
  .filter_map(|(key, value)| value.then_some(key))
83
  .collect(),
84
+ request_timeout: globals.get::<_, u8>("request_timeout")?,
85
  })
86
  })
87
  }