mirror of
https://github.com/vcmi/vcmi.git
synced 2025-11-23 22:37:55 +02:00
JsonNode constructors: Take fileName as argument
* Don't print JSON in JsonParser::parse() in case of errors
This commit is contained in:
@@ -269,7 +269,7 @@ JsonNode JsonUtils::assembleFromFiles(const std::string & filename)
|
||||
for(auto & loader : CResourceHandler::get()->getResourcesWithName(resID))
|
||||
{
|
||||
auto textData = loader->load(resID)->readAll();
|
||||
JsonNode section(reinterpret_cast<std::byte *>(textData.first.get()), textData.second);
|
||||
JsonNode section(reinterpret_cast<std::byte *>(textData.first.get()), textData.second, resID.getName());
|
||||
merge(result, section);
|
||||
}
|
||||
return result;
|
||||
|
||||
Reference in New Issue
Block a user