Fix focusing on submit button when using new noscript captcha.

This commit is contained in:
ccd0 2015-06-20 22:41:34 -07:00
parent 26e38c17b1
commit 19c595ed7c

View File

@ -175,7 +175,7 @@ Captcha.v2 =
$.set 'captchas', @captchas
@count()
focus = d.activeElement?.nodeName is 'IFRAME' and d.activeElement.src?[...38] is 'https://www.google.com/recaptcha/api2/'
focus = d.activeElement?.nodeName is 'IFRAME' and /https?:\/\/www\.google\.com\/recaptcha\//.test(d.activeElement.src)
if @needed()
if focus
if QR.cooldown.auto or Conf['Post on Captcha Completion']