mirror of
https://framagit.org/ppom/reaction
synced 2026-03-14 12:45:47 +01:00
parent
a238c7411f
commit
9642f47512
1 changed files with 7 additions and 0 deletions
|
|
@ -33,6 +33,10 @@ pub struct Config {
|
|||
|
||||
#[serde(default = "dot")]
|
||||
state_directory: String,
|
||||
|
||||
// This field only serve the purpose of having a top-level place for saving YAML variables
|
||||
#[serde(default, skip_serializing, rename = "definitions")]
|
||||
_definitions: serde_json::Value,
|
||||
}
|
||||
|
||||
fn dot() -> String {
|
||||
|
|
@ -74,6 +78,9 @@ impl Config {
|
|||
self.concurrency = num_cpus::get();
|
||||
}
|
||||
|
||||
// Nullify this useless field
|
||||
self._definitions = serde_json::Value::Null;
|
||||
|
||||
let mut new_patterns = BTreeMap::new();
|
||||
for (key, value) in &self.patterns {
|
||||
let mut value = value.as_ref().clone();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue