From 6fd3b64c679d0640796b3fb3d5972fc465bfa954 Mon Sep 17 00:00:00 2001 From: 8chan Date: Sat, 27 Sep 2014 00:44:55 +0000 Subject: [PATCH] Disallow multiple Shrink all images appearing fixes vichan-devel#91 --- js/expand-all-images.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/js/expand-all-images.js b/js/expand-all-images.js index fc273e5e..5545045c 100644 --- a/js/expand-all-images.js +++ b/js/expand-all-images.js @@ -27,7 +27,10 @@ onready(function(){ $(this).parent().click(); }); - $('hr:first').before('
'); + if (!$('#shrink-all-images').length) { + $('hr:first').before('
'); + } + $('div#shrink-all-images a') .text(_('Shrink all images')) .click(function(){