Disallow multiple Shrink all images appearing

fixes vichan-devel#91
This commit is contained in:
8chan 2014-09-27 00:44:55 +00:00 committed by czaks
parent 56f3d89774
commit 6fd3b64c67

View File

@ -27,7 +27,10 @@ onready(function(){
$(this).parent().click(); $(this).parent().click();
}); });
$('hr:first').before('<div id="shrink-all-images" style="text-align:right"><a class="unimportant" href="javascript:void(0)"></a></div>'); if (!$('#shrink-all-images').length) {
$('hr:first').before('<div id="shrink-all-images" style="text-align:right"><a class="unimportant" href="javascript:void(0)"></a></div>');
}
$('div#shrink-all-images a') $('div#shrink-all-images a')
.text(_('Shrink all images')) .text(_('Shrink all images'))
.click(function(){ .click(function(){