From 3e8a0d9c5568be69a9bb3dc4c29aec3f4b9678db Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Benjamin=20Schmith=C3=BCsen?= Date: Mon, 2 Sep 2019 13:41:59 +0200 Subject: [PATCH] don't fail if a scene has no nodes property (which is not required) --- tiny_gltf.h | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/tiny_gltf.h b/tiny_gltf.h index 62c466d..67ed245 100644 --- a/tiny_gltf.h +++ b/tiny_gltf.h @@ -4563,9 +4563,7 @@ bool TinyGLTF::LoadFromString(Model *model, std::string *err, std::string *warn, } const json &o = it->get(); std::vector nodes; - if (!ParseIntegerArrayProperty(&nodes, err, o, "nodes", false)) { - return false; - } + ParseIntegerArrayProperty(&nodes, err, o, "nodes", false)); Scene scene; scene.nodes = std::move(nodes);