From 63b8993c390d867ca3dc57393db68b9d27b81340 Mon Sep 17 00:00:00 2001 From: eight Date: Sat, 2 Feb 2019 15:36:55 +0800 Subject: [PATCH] Change: only use the installation URL as the update URL if not specified in usercss --- install-usercss/install-usercss.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/install-usercss/install-usercss.js b/install-usercss/install-usercss.js index 889da8b8..2361112b 100644 --- a/install-usercss/install-usercss.js +++ b/install-usercss/install-usercss.js @@ -307,9 +307,9 @@ // set updateUrl const checker = $('.set-update-url input[type=checkbox]'); - // prefer the installation URL unless drag'n'dropped on the manage page + // only use the installation URL if not specified in usercss const installationUrl = (params.get('updateUrl') || '').replace(/^blob.+/, ''); - const updateUrl = new URL(installationUrl || style.updateUrl || DUMMY_URL); + const updateUrl = new URL(style.updateUrl || installationUrl || DUMMY_URL); if (dup && dup.updateUrl === updateUrl.href) { checker.checked = true; // there is no way to "unset" updateUrl, you can only overwrite it.