Skip to content
Snippets Groups Projects
Commit 7480d28d authored by Jürgen Haas's avatar Jürgen Haas Committed by Julian Pustkuchen
Browse files

Issue #3507522 by jurgenhaas, anybody: Insert captcha widget even if placement is NULL

parent 48be3794
Branches
Tags 2.0.8
1 merge request!111Issue #3507522 by jurgenhaas: Insert captcha widget even if placement is NULL
Pipeline #555109 failed
......@@ -208,12 +208,11 @@ function captcha_form_alter(array &$form, FormStateInterface $form_state, $form_
];
// Get placement in form and insert in form.
if ($captcha_placement = _captcha_get_captcha_placement($form_id, $form)) {
$captcha_placement = _captcha_get_captcha_placement($form_id, $form);
$captchaService->insertCaptchaElement($form, $captcha_placement, $captcha_element);
}
}
}
}
// If the user has the "skip CAPTCHA" permission, check, if it should be
// rendered in "administration_mode", which adds administrative informations
// to the captcha:
......@@ -273,9 +272,8 @@ function captcha_form_alter(array &$form, FormStateInterface $form_state, $form_
}
// Get placement in form and insert in form.
if ($captcha_placement = _captcha_get_captcha_placement($form_id, $form)) {
$captcha_placement = _captcha_get_captcha_placement($form_id, $form);
$captchaService->insertCaptchaElement($form, $captcha_placement, $captcha_element);
};
}
// If the user has the "skip Captcha" permission, but the
// administration_mode is not enabled, simply do nothing and therefore
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment