diff --git a/src/Posting/QR.captcha.coffee b/src/Posting/QR.captcha.coffee index 672614e74..b59e94f23 100644 --- a/src/Posting/QR.captcha.coffee +++ b/src/Posting/QR.captcha.coffee @@ -84,7 +84,8 @@ QR.captcha = $.set 'captchas', @captchas else challenge = @nodes.img.alt - if response = @nodes.input.value then @destroy() + if response = @nodes.input.value + if Conf['Auto-load captcha'] then @reload() else @destroy() if response response = response.trim() # one-word-captcha: diff --git a/src/Posting/QR.coffee b/src/Posting/QR.coffee index a16f64f1f..81887cbff 100644 --- a/src/Posting/QR.coffee +++ b/src/Posting/QR.coffee @@ -123,6 +123,8 @@ QR = post.delete() QR.cooldown.auto = false QR.status() + if QR.captcha.isEnabled and not Conf['Auto-load captcha'] + QR.captcha.destroy() focusin: -> $.addClass QR.nodes.el, 'focus' focusout: -> @@ -148,9 +150,10 @@ QR = el = err el.removeAttribute 'style' if QR.captcha.isEnabled and /captcha|verification/i.test el.textContent - # Focus the captcha input on captcha error. - QR.captcha.nodes.input.focus() - QR.captcha.setup() + if QR.captcha.captchas.length is 0 + # Focus the captcha input on captcha error. + QR.captcha.nodes.input.focus() + QR.captcha.setup() if Conf['Captcha Warning Notifications'] and !d.hidden QR.notify el else @@ -807,7 +810,7 @@ QR = unless Conf['Persistent QR'] or QR.cooldown.auto QR.close() else - if QR.posts.length > 1 + if QR.posts.length > 1 and QR.captcha.isEnabled and QR.captcha.captchas.length is 0 QR.captcha.setup() post.rm()