From aa3c1abbc0c246eaced424a5714db456e16c0276 Mon Sep 17 00:00:00 2001 From: Paul Kaplan Date: Tue, 14 Jan 2020 11:28:27 -0500 Subject: [PATCH] Support 3.0 library syntax when fetching assets Fixes https://github.com/LLK/scratch-desktop/issues/92 --- scripts/fetchMediaLibraryAssets.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/scripts/fetchMediaLibraryAssets.js b/scripts/fetchMediaLibraryAssets.js index 317db45..f1e6fb3 100644 --- a/scripts/fetchMediaLibraryAssets.js +++ b/scripts/fetchMediaLibraryAssets.js @@ -23,10 +23,14 @@ const collectSimple = function (library, dest, debugLabel = 'Item') { ++md5Count; dest.add(item.md5); } - if (item.baseLayerMD5) { + if (item.baseLayerMD5) { // 2.0 library syntax for costumes ++md5Count; dest.add(item.baseLayerMD5); } + if (item.md5ext) { // 3.0 library syntax for costumes + ++md5Count; + dest.add(item.md5ext); + } if (md5Count < 1) { console.warn(`${debugLabel} has no MD5 property:\n${describe(item)}`); } else if (md5Count > 1) {