diff --git a/4chan_x.user.js b/4chan_x.user.js index d5489ceb1..c63b4d499 100644 --- a/4chan_x.user.js +++ b/4chan_x.user.js @@ -3712,7 +3712,7 @@ node: function(post) { var gif, img, src; img = post.img; - if (post.root.hidden || !img) { + if (post.el.hidden || !img) { return; } src = img.parentNode.href; @@ -3738,7 +3738,7 @@ } a = post.img.parentNode; $.on(a, 'click', ImageExpand.cb.toggle); - if (ImageExpand.on && !post.root.hidden && post["class"] !== 'inline') { + if (ImageExpand.on && !post.el.hidden && post["class"] !== 'inline') { return ImageExpand.expand(post.img); } }, diff --git a/script.coffee b/script.coffee index fb0cf70bb..44ca9c4b0 100644 --- a/script.coffee +++ b/script.coffee @@ -2846,7 +2846,7 @@ AutoGif = Main.callbacks.push @node node: (post) -> {img} = post - return if post.root.hidden or not img + return if post.el.hidden or not img src = img.parentNode.href if /gif$/.test(src) and !/spoiler/.test img.src gif = $.el 'img' @@ -2864,7 +2864,7 @@ ImageExpand = return unless post.img a = post.img.parentNode $.on a, 'click', ImageExpand.cb.toggle - if ImageExpand.on and !post.root.hidden and post.class isnt 'inline' + if ImageExpand.on and !post.el.hidden and post.class isnt 'inline' ImageExpand.expand post.img cb: toggle: (e) ->