From 51f257d2ff9ceeed8931c7f75d8eae5483cd709e Mon Sep 17 00:00:00 2001 From: Xmader Date: Sat, 24 Jul 2021 01:52:17 -0400 Subject: [PATCH] v0.24.3 --- dist/main.js | 15 +++++++++++++-- package-lock.json | 2 +- package.json | 2 +- 3 files changed, 15 insertions(+), 4 deletions(-) diff --git a/dist/main.js b/dist/main.js index 32d171e..53e9ec9 100644 --- a/dist/main.js +++ b/dist/main.js @@ -5,7 +5,7 @@ // @supportURL https://github.com/Xmader/musescore-downloader/issues // @updateURL https://msdl.librescore.org/install.user.js // @downloadURL https://msdl.librescore.org/install.user.js -// @version 0.24.2 +// @version 0.24.3 // @description download sheet music from musescore.com for free, no login or Musescore Pro required | 免登录、免 Musescore Pro,免费下载 musescore.com 上的曲谱 // @author Xmader // @icon https://librescore.org/img/icons/logo.svg @@ -26657,7 +26657,18 @@ Please pipe the document into a Node stream.\ } } } - return magic; + try { + return yield useTimeout(magic, 5 * 1000 /* 5s */); + } + catch (_b) { + console$1.error(type, 'token timeout'); + switch (type) { + // try hard-coded tokens + case 'img': return '8c022bdef45341074ce876ae57a48f64b86cdcf5'; + case 'midi': return '38fb9efaae51b0c83b5bb5791a698b48292129e7'; + case 'mp3': return '63794e5461e4cfa046edfbdddfccc1ac16daffd2'; + } + } }); const getFileUrl = (id, type, index = 0) => __awaiter(void 0, void 0, void 0, function* () { const url = getApiUrl(id, type, index); diff --git a/package-lock.json b/package-lock.json index d4f05c7..4b4d3dd 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "musescore-downloader", - "version": "0.24.2", + "version": "0.24.3", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index e65c727..da67e7d 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "musescore-downloader", - "version": "0.24.2", + "version": "0.24.3", "description": "download sheet music from musescore.com for free, no login or Musescore Pro required | 免登录、免 Musescore Pro,免费下载 musescore.com 上的曲谱", "main": "dist/main.js", "bin": "dist/cli.js",