diff --git a/4chan_x.coffee b/4chan_x.coffee index c7cc118d0..600e6e45b 100644 --- a/4chan_x.coffee +++ b/4chan_x.coffee @@ -646,7 +646,7 @@ qrText = (link) -> selection = window.getSelection() id = x('preceding::span[@id][1]', selection.anchorNode)?.id - text += selection.toString() if id is link.id + text += selection.toString() if id is link.parentNode.id text diff --git a/4chan_x.js b/4chan_x.js index 689371b24..9c24d0340 100644 --- a/4chan_x.js +++ b/4chan_x.js @@ -844,7 +844,7 @@ text = '>>' + link.parentNode.id.match(/\d+$/)[0] + '\n'; selection = window.getSelection(); id = (_ref = x('preceding::span[@id][1]', selection.anchorNode)) != null ? _ref.id : void 0; - if (id === link.id) { + if (id === link.parentNode.id) { text += selection.toString(); } return text;