mirror of
https://github.com/izzy2lost/libultraship.git
synced 2026-06-19 01:16:13 -07:00
Allow writing new blocks to config (#956)
* Fix bug with writing new blocks to config Co-authored-by: Garrett Cox <garrettjcox@gmail.com> * Always assign the block regardless of key presence --------- Co-authored-by: Garrett Cox <garrettjcox@gmail.com>
This commit is contained in:
@@ -154,9 +154,7 @@ void Config::SetBlock(const std::string& key, nlohmann::json block) {
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if (gjson.contains(key)) {
|
||||
gjson[key] = block;
|
||||
}
|
||||
gjson[key] = block;
|
||||
}
|
||||
mFlattenedJson = gjson.flatten();
|
||||
Save();
|
||||
|
||||
Reference in New Issue
Block a user