mirror of
https://git.mirrors.martin98.com/https://github.com/syoyo/tinygltf.git
synced 2025-08-14 05:26:02 +08:00
Merge pull request #100 from Selmar/serialization_fixes
yet another serialization fix
This commit is contained in:
commit
3b25d9130a
@ -4126,7 +4126,8 @@ static void SerializeExtensionMap(ExtensionMap &extensions, json &o) {
|
||||
json ret;
|
||||
if (ValueToJson(extIt->second, &ret)) {
|
||||
extMap[extIt->first] = ret;
|
||||
} else {
|
||||
}
|
||||
if(ret.is_null()) {
|
||||
if (!(extIt->first.empty())) { // name should not be empty, but for sure
|
||||
// create empty object so that an extension name is still included in json.
|
||||
extMap[extIt->first] = json({});
|
||||
|
Loading…
x
Reference in New Issue
Block a user