Update comment. You can read the timeout in seconde in the recaptcha script/object. Unfortunately 4chan X cannot access it.

This commit is contained in:
Nicolas Stepien 2011-12-09 20:40:46 +01:00
parent 33cfbe8220
commit 2af711f8af
2 changed files with 4 additions and 4 deletions

View File

@ -1639,8 +1639,8 @@
content = $('textarea', qr.el).value || $('input[type=file]', qr.el).files.length; content = $('textarea', qr.el).value || $('input[type=file]', qr.el).files.length;
if (!content) return 'Error: No text entered.'; if (!content) return 'Error: No text entered.';
/* /*
captchas expire after 30 minutes (emperically verified). cutoff 5 minutes captchas expire after 30 minutes, see window.RecaptchaState.timeout.
before then, b/c posting takes time. cutoff 5 minutes before then, b/c posting takes time.
*/ */
cutoff = Date.now() - 25 * MINUTE; cutoff = Date.now() - 25 * MINUTE;
captchas = $.get('captchas', []); captchas = $.get('captchas', []);

View File

@ -1274,8 +1274,8 @@ qr =
return 'Error: No text entered.' unless content return 'Error: No text entered.' unless content
### ###
captchas expire after 30 minutes (emperically verified). cutoff 5 minutes captchas expire after 30 minutes, see window.RecaptchaState.timeout.
before then, b/c posting takes time. cutoff 5 minutes before then, b/c posting takes time.
### ###
cutoff = Date.now() - 25*MINUTE cutoff = Date.now() - 25*MINUTE