public function LightningApiServiceProvider::alter in Lightning API 8
Same name and namespace in other branches
- 8.4 src/LightningApiServiceProvider.php \Drupal\lightning_api\LightningApiServiceProvider::alter()
- 8.2 src/LightningApiServiceProvider.php \Drupal\lightning_api\LightningApiServiceProvider::alter()
- 8.3 src/LightningApiServiceProvider.php \Drupal\lightning_api\LightningApiServiceProvider::alter()
Modifies existing service definitions.
Parameters
ContainerBuilder $container: The ContainerBuilder whose service definitions can be altered.
Overrides ServiceProviderBase::alter
File
- src/
LightningApiServiceProvider.php, line 13
Class
Namespace
Drupal\lightning_apiCode
public function alter(ContainerBuilder $container) {
parent::alter($container);
if ($container
->hasDefinition('metatag.normalizer.metatag_field')) {
$container
->getDefinition('metatag.normalizer.metatag_field')
->clearTag('normalizer');
}
if ($container
->hasDefinition('metatag.normalizer.metatag')) {
$container
->getDefinition('metatag.normalizer.metatag')
->clearTag('normalizer');
}
if ($container
->hasDefinition('metatag.normalizer.metatag.hal')) {
$container
->getDefinition('metatag.normalizer.metatag.hal')
->clearTag('normalizer');
}
}