From dcb734afff044e9701c084d537fb9935934753ae Mon Sep 17 00:00:00 2001 From: Zixaphir Date: Sat, 11 Jan 2014 14:54:41 -0700 Subject: [PATCH] Small fix to backlinks code --- builds/4chan-X.user.js | 8 ++++---- builds/crx/script.js | 8 ++++---- src/Quotelinks/QuoteBacklink.coffee | 6 +++--- 3 files changed, 11 insertions(+), 11 deletions(-) diff --git a/builds/4chan-X.user.js b/builds/4chan-X.user.js index 8fcd0920a..9a51ffe7f 100644 --- a/builds/4chan-X.user.js +++ b/builds/4chan-X.user.js @@ -4708,7 +4708,7 @@ }); }, firstNode: function() { - var a, clone, container, containers, frag, link, post, quote, _i, _j, _k, _len, _len1, _len2, _ref, _ref1; + var a, clone, container, containers, link, nodes, post, quote, _i, _j, _k, _len, _len1, _len2, _ref, _ref1; if (this.isClone || !this.quotes.length) { return; } @@ -4730,17 +4730,17 @@ } for (_k = 0, _len2 = containers.length; _k < _len2; _k++) { container = containers[_k]; - frag = [$.tn(' '), link = a.cloneNode(true)]; + nodes = [$.tn(' '), link = a.cloneNode(true)]; if (Conf['Quote Previewing']) { $.on(link, 'mouseover', QuotePreview.mouseover); } if (Conf['Quote Inlining']) { $.on(link, 'click', QuoteInline.toggle); if (Conf['Quote Hash Navigation']) { - frag.push.apply(frag, QuoteInline.qiQuote(link, $.hasClass(link, 'filtered'))); + nodes.push(QuoteInline.qiQuote(link, $.hasClass(link, 'filtered'))); } } - $.add(container, frag); + $.add(container, nodes); } } }, diff --git a/builds/crx/script.js b/builds/crx/script.js index e8fd2a088..f29b864e3 100644 --- a/builds/crx/script.js +++ b/builds/crx/script.js @@ -4711,7 +4711,7 @@ }); }, firstNode: function() { - var a, clone, container, containers, frag, link, post, quote, _i, _j, _k, _len, _len1, _len2, _ref, _ref1; + var a, clone, container, containers, link, nodes, post, quote, _i, _j, _k, _len, _len1, _len2, _ref, _ref1; if (this.isClone || !this.quotes.length) { return; } @@ -4733,17 +4733,17 @@ } for (_k = 0, _len2 = containers.length; _k < _len2; _k++) { container = containers[_k]; - frag = [$.tn(' '), link = a.cloneNode(true)]; + nodes = [$.tn(' '), link = a.cloneNode(true)]; if (Conf['Quote Previewing']) { $.on(link, 'mouseover', QuotePreview.mouseover); } if (Conf['Quote Inlining']) { $.on(link, 'click', QuoteInline.toggle); if (Conf['Quote Hash Navigation']) { - frag.push.apply(frag, QuoteInline.qiQuote(link, $.hasClass(link, 'filtered'))); + nodes.push(QuoteInline.qiQuote(link, $.hasClass(link, 'filtered'))); } } - $.add(container, frag); + $.add(container, nodes); } } }, diff --git a/src/Quotelinks/QuoteBacklink.coffee b/src/Quotelinks/QuoteBacklink.coffee index a5de2fa96..95d056571 100755 --- a/src/Quotelinks/QuoteBacklink.coffee +++ b/src/Quotelinks/QuoteBacklink.coffee @@ -36,13 +36,13 @@ QuoteBacklink = for clone in post.clones containers.push clone.nodes.backlinkContainer for container in containers - frag = [$.tn(' '), link = a.cloneNode true] + nodes = [$.tn(' '), link = a.cloneNode true] if Conf['Quote Previewing'] $.on link, 'mouseover', QuotePreview.mouseover if Conf['Quote Inlining'] $.on link, 'click', QuoteInline.toggle - frag.push.apply frag, QuoteInline.qiQuote link, $.hasClass link, 'filtered' if Conf['Quote Hash Navigation'] - $.add container, frag + nodes.push QuoteInline.qiQuote link, $.hasClass link, 'filtered' if Conf['Quote Hash Navigation'] + $.add container, nodes return secondNode: -> if @isClone and (@origin.isReply or Conf['OP Backlinks'])