";
qr.el = ui.dialog('qr', {
top: '0px',
left: '0px'
@@ -1411,6 +1412,13 @@
},
submit: function(e) {
var id, isQR, op;
+ if ($('#recaptcha_response_field', qr.el).value === '') {
+ e.preventDefault();
+ if (!qr.autoPost()) {
+ alert('You forgot to type in the verification.');
+ }
+ return;
+ }
if (conf['Auto Watch Reply'] && conf['Thread Watcher']) {
if (g.REPLY && $('img.favicon').src === Favicon.empty) {
watcher.watch(null, g.THREAD_ID);
diff --git a/script.coffee b/script.coffee
index f1e87544a..29c986966 100644
--- a/script.coffee
+++ b/script.coffee
@@ -1011,6 +1011,8 @@ qr =
responseField.value = captcha.response
qr.submit.call $ 'form', qr.el
+ true
+
captchaNode: (e) ->
return unless qr.el
{target} = e
@@ -1062,7 +1064,7 @@ qr =
-
#{$.get('captchas', []).length} captchas
+
#{$.get('captchas', []).length} captchas
@@ -1152,6 +1154,12 @@ qr =
$('input[name=pwd]', qr.el).value = if m = c.match(/4chan_pass=([^;]+)/) then decodeURIComponent m[1] else $('input[name=pwd]').value
submit: (e) ->
+ if $('#recaptcha_response_field', qr.el).value is ''
+ e.preventDefault()
+ unless qr.autoPost()
+ alert 'You forgot to type in the verification.'
+ return
+
if conf['Auto Watch Reply'] and conf['Thread Watcher']
if g.REPLY and $('img.favicon').src is Favicon.empty
watcher.watch null, g.THREAD_ID