maikschneider / bw_captcha

TYPO3 extension that adds a captcha element with audio support for the TYPO3 form component. The captcha generation uses Gregwar/Captcha, no Google or 3rd party includes.
6 stars 7 forks source link

Check if $GLOBALS['TSFE'] is initialized #26

Closed sypets closed 1 year ago

sypets commented 1 year ago

If the hook FormElementCaptchaHook is executed in the backend in preview mode, $GLOBALS['TSFE'] may not be initialized.

Also, it is no longer considered good practice to access $GLOBALS['TSFE'] directly, but an alternative is missing in this case.

Resolves: #25