public function ContentTranslationConfigOverrideBase::getCacheableMetadata in Open Social 10.0.x
Same name and namespace in other branches
- 8.9 modules/social_features/social_core/src/ContentTranslationConfigOverrideBase.php \Drupal\social_core\ContentTranslationConfigOverrideBase::getCacheableMetadata()
- 8.4 modules/social_features/social_core/src/ContentTranslationConfigOverrideBase.php \Drupal\social_core\ContentTranslationConfigOverrideBase::getCacheableMetadata()
- 8.5 modules/social_features/social_core/src/ContentTranslationConfigOverrideBase.php \Drupal\social_core\ContentTranslationConfigOverrideBase::getCacheableMetadata()
- 8.6 modules/social_features/social_core/src/ContentTranslationConfigOverrideBase.php \Drupal\social_core\ContentTranslationConfigOverrideBase::getCacheableMetadata()
- 8.7 modules/social_features/social_core/src/ContentTranslationConfigOverrideBase.php \Drupal\social_core\ContentTranslationConfigOverrideBase::getCacheableMetadata()
- 8.8 modules/social_features/social_core/src/ContentTranslationConfigOverrideBase.php \Drupal\social_core\ContentTranslationConfigOverrideBase::getCacheableMetadata()
- 10.3.x modules/social_features/social_core/src/ContentTranslationConfigOverrideBase.php \Drupal\social_core\ContentTranslationConfigOverrideBase::getCacheableMetadata()
- 10.1.x modules/social_features/social_core/src/ContentTranslationConfigOverrideBase.php \Drupal\social_core\ContentTranslationConfigOverrideBase::getCacheableMetadata()
- 10.2.x modules/social_features/social_core/src/ContentTranslationConfigOverrideBase.php \Drupal\social_core\ContentTranslationConfigOverrideBase::getCacheableMetadata()
Gets the cacheability metadata associated with the config factory override.
Parameters
string $name: The name of the configuration override to get metadata for.
Return value
\Drupal\Core\Cache\CacheableMetadata A cacheable metadata object.
Overrides ConfigFactoryOverrideInterface::getCacheableMetadata
File
- modules/
social_features/ social_core/ src/ ContentTranslationConfigOverrideBase.php, line 95
Class
- ContentTranslationConfigOverrideBase
- Provides a base class for configurable content translation config overrides.
Namespace
Drupal\social_coreCode
public function getCacheableMetadata($name) {
$metadata = new CacheableMetadata();
if (in_array($name, $this
->getOverriddenConfigurations())) {
$metadata
->addCacheTags([
'config:social_content_translation.settings',
]);
}
return $metadata;
}