diff --git a/core/lib/Drupal/Core/Config/TypedConfigManager.php b/core/lib/Drupal/Core/Config/TypedConfigManager.php index 64735ad..54c836f 100644 --- a/core/lib/Drupal/Core/Config/TypedConfigManager.php +++ b/core/lib/Drupal/Core/Config/TypedConfigManager.php @@ -285,4 +285,18 @@ protected function replaceVariable($value, $data) { } } + /** + * Checks if the config schema with the given config name exists. + * + * @param string $name + * Configuration name. + * + * @return bool + * TRUE if schema exists, FALSE otherwise. + */ + public function hasConfigSchema($name) { + $definition = $this->getDefinition($name); + return is_array($definition) && $definition['class'] != '\Drupal\Core\Config\Schema\Property'; + } + }