Issue #1024370 by soxofaan, nineLemon, Pancho, slashrsm: Prevents CAPTCHA from failin...
authorFabiano Sant'Ana
Wed, 27 Apr 2011 20:50:36 +0000 (17:50 -0300)
committerFabiano Sant'Ana
Wed, 27 Apr 2011 20:50:36 +0000 (17:50 -0300)
captcha.module

index 8b4adbd..9128b61 100644 (file)
@@ -208,6 +208,8 @@ function captcha_element_process($element, &$form_state, $complete_form) {
   else {
     // Generate a new CAPTCHA session if we could not reuse one from a posted form.
     $captcha_sid = _captcha_generate_captcha_session($this_form_id, CAPTCHA_STATUS_UNSOLVED);
+    // Set $posted_form_id during the first rendering of the form.
+    $posted_form_id = $this_form_id;
   }
 
   // Store CAPTCHA session ID as hidden field.