You are here

public function ConfigNamesMapper::hasTranslatable in Drupal 9

Same name and namespace in other branches
  1. 8 core/modules/config_translation/src/ConfigNamesMapper.php \Drupal\config_translation\ConfigNamesMapper::hasTranslatable()

Checks if pieces of this configuration mapper have translatables.

Return value

bool TRUE if at least one of the configuration elements has translatables, FALSE otherwise.

Overrides ConfigMapperInterface::hasTranslatable

File

core/modules/config_translation/src/ConfigNamesMapper.php, line 455

Class

ConfigNamesMapper
Configuration mapper base implementation.

Namespace

Drupal\config_translation

Code

public function hasTranslatable() {
  foreach ($this
    ->getConfigNames() as $name) {
    if ($this->configMapperManager
      ->hasTranslatable($name)) {
      return TRUE;
    }
  }
  return FALSE;
}