From eeeecc7d93e785add66601dee6b0d961cdebc07b Mon Sep 17 00:00:00 2001 From: Nicolas Stepien Date: Wed, 20 Jul 2011 20:23:14 +0200 Subject: [PATCH] Return asap. --- 4chan_x.user.js | 2 +- script.coffee | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/4chan_x.user.js b/4chan_x.user.js index 580a8c652..11c03e822 100644 --- a/4chan_x.user.js +++ b/4chan_x.user.js @@ -1859,7 +1859,7 @@ init: function() { return g.callbacks.push(function(root) { var board, img, nb, _, _ref; - if (root.className === 'inline' || !(img = $('img[alt^=Spoiler]', root))) { + if (!(img = $('img[alt^=Spoiler]', root) || root.className === 'inline')) { return; } img.removeAttribute('height'); diff --git a/script.coffee b/script.coffee index e5245a5f7..70b84b433 100644 --- a/script.coffee +++ b/script.coffee @@ -1486,7 +1486,7 @@ sauce = revealSpoilers = init: -> g.callbacks.push (root) -> - return if root.className is 'inline' or not img = $ 'img[alt^=Spoiler]', root + return if not img = $('img[alt^=Spoiler]', root) or root.className is 'inline' img.removeAttribute 'height' img.removeAttribute 'width' [_, board, nb] = img.parentNode.href.match /(\w+)\/src\/(\d+)/