xperseguers / t3ext-ig_ldap_sso_auth

TYPO3 Extension ig_ldap_sso_auth. This extension provides LDAP and SSO support for TYPO3.
https://extensions.typo3.org/extension/ig_ldap_sso_auth
27 stars 62 forks source link

[BUGFIX] Remove deprecated approach to init TSFE #110

Closed NormenKD closed 3 years ago

NormenKD commented 3 years ago

Typo3 v10 changed how TSFE is constructed. makeInstance() has been updated and all necessary arguments have been fetched with core api. Also, $GLOBALS['TSFE']->initTemplate() has been removed. It has been replaced with the suggested replacement approach.

I came across this error in a new Typo3 v10 installation with LDAP frontend login (LDAP backend login worked fine):

1561583122 InvalidArgumentException

TypoScriptFrontendController must be constructed with a valid Site object or a resolved site in the current request as fallback. None given.

This traced to the TSFE instantiation around "ext/ig_ldap_sso_auth/Classes/Library/Authentication.php line 694" which seemed to be outdated.

I hope you can use this for the next release, thank you for your time and effort.

NormenKD commented 3 years ago

I added a version check for the new code path, similarly to how it is done in other parts of this extension. I kept the old approach for versions below Typo3 v10. Hopefully this is was you had in mind. :smile:

xperseguers commented 3 years ago

Minor changed applied, to be reviewed as #121