Project

General

Profile

Bug #91316

Updated by Helmut Hummel over 4 years ago

Reported by Aristeidis Karavas (Apr 28th at 11:51) via Slack: 
 https://typo3.slack.com/archives/C025BQLFA/p1588067478426300 

 > Why in TYPO3 v10 this won't set the meta tags in frontend? 
 > $metaTag = $this->metaTagManagerRegistry->getManagerForProperty($key); 
 > $metaTag->addProperty($key, $metaTagValue); 
 > If i debug it, it sets everything right but it won't be displayed in the frontend 

 The reason is that the PageRenderer stores a new Singleton via    @GeneralUtility::setSingletonInstance@ in @__wakeup@. 

 


 That updates @MetaTagManagerRegistry@ instances retrieved via @GeneralUtility::makeInstance@, but not those injected via symfony DI, 
 where DI (where the object will already have been generated, as it is loaded during EXT:seo/ext_localconf.php loading and GeneralUtility::makeInstance 
 will call the DI container. 

 loading). 


 This issues happens when the PageRenderer was serialized and is unserialized for @USER_INT@ plugins (e.g. uncached extbase plugins). 

 Same applies to AssetCollector, which is serialized and unserialized as well. Aristeidis Karavas did not yet confirm that has was actually using an uncached plugin, that's my guess currently. 

Back