mirror of
https://github.com/murdos/musicbrainz-userscripts
synced 2024-12-13 11:52:27 +00:00
Remove old Script Update Checker
This commit is contained in:
parent
be2d8bab13
commit
753ea9b1bd
1 changed files with 1 additions and 6 deletions
|
@ -1,7 +1,7 @@
|
|||
// ==UserScript==
|
||||
|
||||
// @name Import Discogs releases to MusicBrainz
|
||||
// @version 2012.12.08.1
|
||||
// @version 2012.12.08.2
|
||||
// @namespace http://userscripts.org/users/22504
|
||||
// @icon http://www.discogs.com/images/discogs130.png
|
||||
// @downloadURL https://raw.github.com/murdos/musicbrainz-userscripts/master/discogs_importer.user.js
|
||||
|
@ -17,11 +17,6 @@
|
|||
// @require https://raw.github.com/murdos/musicbrainz-userscripts/master/lib/import_functions.js
|
||||
// ==/UserScript==
|
||||
|
||||
// Script Update Checker
|
||||
// -- http://userscripts.org/scripts/show/20145
|
||||
var SUC_script_num = 36376;
|
||||
try{function updateCheck(forced){if ((forced) || (parseInt(GM_getValue('SUC_last_update', '0')) + 86400000 <= (new Date().getTime()))){try{GM_xmlhttpRequest({method: 'GET',url: 'http://userscripts.org/scripts/source/'+SUC_script_num+'.meta.js?'+new Date().getTime(),headers: {'Cache-Control': 'no-cache'},onload: function(resp){var local_version, remote_version, rt, script_name;rt=resp.responseText;GM_setValue('SUC_last_update', new Date().getTime()+'');remote_version=parseInt(/@uso:version\s*(.*?)\s*$/m.exec(rt)[1]);local_version=parseInt(GM_getValue('SUC_current_version', '-1'));if(local_version!=-1){script_name = (/@name\s*(.*?)\s*$/m.exec(rt))[1];GM_setValue('SUC_target_script_name', script_name);if (remote_version > local_version){if(confirm('There is an update available for the Greasemonkey script "'+script_name+'."\nWould you like to go to the install page now?')){GM_openInTab('http://userscripts.org/scripts/show/'+SUC_script_num);GM_setValue('SUC_current_version', remote_version);}}else if (forced)alert('No update is available for "'+script_name+'."');}else GM_setValue('SUC_current_version', remote_version+'');}});}catch (err){if (forced)alert('An error occurred while checking for updates:\n'+err);}}}GM_registerMenuCommand(GM_getValue('SUC_target_script_name', '???') + ' - Manual Update Check', function(){updateCheck(true);});updateCheck(false);}catch(err){}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
if (!unsafeWindow) unsafeWindow = window;
|
||||
|
|
Loading…
Reference in a new issue