Skip to content

Commit daadb7d

Browse files
committed
Fixes download button for 'my models'
1 parent 7d9dbee commit daadb7d

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

UnityGLTF/Assets/UnityGLTF/Scripts/Sketchfab/AssetBrowser/SketchfabBrowserManager.cs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,14 @@ public void parseModelData(JSONNode node)
9696
hasAnimation = node["animationCount"].AsInt > 0 ? "Yes" : "No";
9797
licenseJson = node["license"].AsObject;
9898

99+
// "My models" results don't have any license as they are "private download"
100+
// for the author.
101+
if(licenseJson.ToString() == "{}")
102+
{
103+
isModelAvailable = archiveSize > 0;
104+
return;
105+
}
106+
99107
formattedLicenseRequirements = licenseJson["requirements"];
100108

101109
if (formattedLicenseRequirements.Length > 0)

0 commit comments

Comments
 (0)