dynamic::Value simplified

This commit is contained in:
MihailRis
2024-05-07 18:39:12 +03:00
parent 8e83a07094
commit a4c21984d5
26 changed files with 230 additions and 297 deletions
+2 -2
View File
@@ -88,11 +88,11 @@ void ContentLoader::fixPackIndices() {
auto blocksFolder = folder/ContentPack::BLOCKS_FOLDER;
auto itemsFolder = folder/ContentPack::ITEMS_FOLDER;
std::unique_ptr<dynamic::Map> root;
dynamic::Map_sptr root;
if (fs::is_regular_file(indexFile)) {
root = files::read_json(indexFile);
} else {
root.reset(new dynamic::Map());
root = std::make_shared<dynamic::Map>();
}
bool modified = false;