From 2f8ae8755cb5f5406986d896e0878eba1ff7e57a Mon Sep 17 00:00:00 2001 From: Nicolas Stepien Date: Mon, 28 Nov 2011 23:28:22 +0100 Subject: [PATCH] Fix an unharmful issue, test if the class exists correctly. --- 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 be4f8facb..b18e1204d 100644 --- a/4chan_x.user.js +++ b/4chan_x.user.js @@ -2411,7 +2411,7 @@ root = q.parentNode.nodeName === 'FONT' ? q.parentNode : q.nextSibling ? q.nextSibling : q; if (el = $.id(id)) { inline = quoteInline.table(id, el.innerHTML); - if (q.className === 'backlink') { + if (/\bbacklink\b/.test(q.className)) { $.after(q.parentNode, inline); return; } diff --git a/script.coffee b/script.coffee index dcbea2bbe..57146bb22 100644 --- a/script.coffee +++ b/script.coffee @@ -1888,7 +1888,7 @@ quoteInline = root = if q.parentNode.nodeName is 'FONT' then q.parentNode else if q.nextSibling then q.nextSibling else q if el = $.id id inline = quoteInline.table id, el.innerHTML - if q.className is 'backlink' + if /\bbacklink\b/.test q.className $.after q.parentNode, inline return $.after root, inline