diff --git a/4chan_x.user.js b/4chan_x.user.js index 7354071b0..822cfdf33 100644 --- a/4chan_x.user.js +++ b/4chan_x.user.js @@ -1455,7 +1455,7 @@ return QR.attachNext(); }, submit: function(e) { - var captcha, challenge, el, qr, response; + var captcha, challenge, el, id, op, qr, response; if (!($('textarea', QR.qr).value || $('[type=file]', QR.qr).files.length)) { if (e) { alert('Error: No text entered.'); @@ -1484,7 +1484,14 @@ if (!e) { $('#qr_form', qr).submit(); } - return QR.sage = /sage/i.test($('[name=email]', qr).value); + QR.sage = /sage/i.test($('[name=email]', qr).value); + if (conf['Thread Watcher'] && conf['Auto Watch Reply']) { + id = $('input[name=resto]', qr.el).value; + op = $.id(id); + if ($('img.favicon', op).src === Favicon.empty) { + return watcher.watch(op, id); + } + } }, sys: function() { return $.globalEval(function() { diff --git a/script.coffee b/script.coffee index 52eb23c83..914397a27 100644 --- a/script.coffee +++ b/script.coffee @@ -1159,6 +1159,11 @@ QR = $('#autohide', qr).checked = true if conf['Auto Hide QR'] $('#qr_form', qr).submit() if not e QR.sage = /sage/i.test $('[name=email]', qr).value + if conf['Thread Watcher'] and conf['Auto Watch Reply'] + id = $('input[name=resto]', qr.el).value + op = $.id id + if $('img.favicon', op).src is Favicon.empty + watcher.watch op, id sys: -> $.globalEval -> if node = document.querySelector('table font b')?.firstChild