Commit 162bb5d1 authored by sjerdo's avatar sjerdo Committed by Jakob Perry
Browse files

Issue #3152792 by sjerdo: Solution is reset for form IDs containing a dash

parent 483dfcf3
...@@ -101,7 +101,7 @@ class Captcha extends FormElement implements ContainerFactoryPluginInterface { ...@@ -101,7 +101,7 @@ class Captcha extends FormElement implements ContainerFactoryPluginInterface {
// Get the form ID of the form we are currently processing (which is not // Get the form ID of the form we are currently processing (which is not
// necessary the same form that is submitted (if any). // necessary the same form that is submitted (if any).
$this_form_id = isset($complete_form['form_id']['#value']) ? $this_form_id = isset($complete_form['form_id']['#value']) ?
preg_replace("/[^a-z0-9_]/", "", (string) $complete_form['form_id']['#value']) preg_replace("/[^a-z0-9_-]/", "", (string) $complete_form['form_id']['#value'])
: NULL; : NULL;
// Get the CAPTCHA session ID. // Get the CAPTCHA session ID.
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment