Loading
fix: #3375618 Show the image CAPTCHA refresh link for the 'default' type
Closes #3375618
'#captcha_type' => 'default' (and omitting #captcha_type) already resolves to the configured default challenge. But ImageCaptchaRenderService::imageCaptchaAfterBuildProcess() compared the raw #captcha_type with 'image_captcha/Image', so when Image was the default challenge the image rendered without its refresh link.
The callback now resolves the type through _captcha_parse_captcha_type() before comparing. Rebased onto the flattened callback from #3589845.
Adds an image_captcha_test form that uses 'default' and a functional test asserting the refresh link is present. It fails without the fix. Full suite green on Drupal 10.6.6 and 11.