Provides a better original image link, using _1 instead of _0

Since some time _0 images which are PNGs are truncated at the bottom, using _1 instead
seems to provide the same but correct image.
This commit is contained in:
Laurent Monin 2016-07-30 19:31:18 +02:00
parent 8eb66c1e4b
commit 044037ab49
No known key found for this signature in database
GPG key ID: D859F01B646C07A7

View file

@ -1,7 +1,7 @@
// ==UserScript==
// @name Import Bandcamp releases to MusicBrainz
// @description Add a button on Bandcamp's album pages to open MusicBrainz release editor with pre-filled data for the selected release
// @version 2016.05.29.0
// @version 2016.07.30.0
// @namespace http://userscripts.org/users/22504
// @downloadURL https://raw.github.com/murdos/musicbrainz-userscripts/master/bandcamp_importer.user.js
// @updateURL https://raw.github.com/murdos/musicbrainz-userscripts/master/bandcamp_importer.user.js
@ -292,7 +292,7 @@ $(document).ready(function () {
$("div.tralbum-tags a:not(:last-child)").after(",");
// append a link to the full size image
var fullsizeimageurl = $("div#tralbumArt a").attr("href").replace('_10', '_0');
var fullsizeimageurl = $("div#tralbumArt a").attr("href").replace('_10', '_1');
$("div#tralbumArt").after("<div id='bci_link'><a class='custom-color' href='" + fullsizeimageurl +
"' title='Open original image in a new tab (Bandcamp importer)' target='_blank'>Original image</a></div>");