From 2fe7837775d954b4073b0cdd0d6d5ac209aa5dd2 Mon Sep 17 00:00:00 2001 From: Xmader Date: Mon, 26 Oct 2020 18:23:10 -0400 Subject: [PATCH] v0.9.8 - #41 --- dist/main.js | 17 ++++++++++------- package.json | 2 +- 2 files changed, 11 insertions(+), 8 deletions(-) diff --git a/dist/main.js b/dist/main.js index 997584b..74693bf 100644 --- a/dist/main.js +++ b/dist/main.js @@ -3,7 +3,7 @@ // @namespace https://www.xmader.com/ // @homepageURL https://github.com/Xmader/musescore-downloader/ // @supportURL https://github.com/Xmader/musescore-downloader/issues -// @version 0.9.7 +// @version 0.9.8 // @description download sheet music from musescore.com for free, no login or Musescore Pro required | 免登录、免 Musescore Pro,免费下载 musescore.com 上的曲谱 // @author Xmader // @match https://musescore.com/*/* @@ -26647,14 +26647,17 @@ Please pipe the document into a Node stream.\ const txt = x.textContent; return txt.includes('Download') || txt.includes('Print'); }); + // Anti-detection: + // musescore will send a track event "MSCZDOWNLOADER_INSTALLED" to its backend + // if detected "Download MSCZ" + const _property = 'textContent'; + const _set = textNode['__lookupSetter__'](_property); + Object.defineProperty(textNode, _property, { + set(v) { _set.call(textNode, v); }, + get() { return 'Download'; }, + }); const setText = (str) => { textNode.textContent = str; - // Anti-detection: - // musescore will send a track event "MSCZDOWNLOADER_INSTALLED" to its backend - // if detected "Download MSCZ" - Object.defineProperty(textNode, 'textContent', { - get() { return 'Download'; }, - }); }; setText(options.name); btn.onclick = () => { diff --git a/package.json b/package.json index 89376ed..445010b 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "musescore-downloader", - "version": "0.9.7", + "version": "0.9.8", "description": "download sheet music from musescore.com for free, no login or Musescore Pro required | 免登录、免 Musescore Pro,免费下载 musescore.com 上的曲谱", "main": "dist/main.js", "repository": {