X-Git-Url: http://aleph1.co.uk/gitweb/?a=blobdiff_plain;f=web%2Fcore%2Flib%2FDrupal%2FCore%2FPlugin%2FDefaultPluginManager.php;h=c74fcbe958fb19e94bd2277a5384dfef58eb96b5;hb=af6d1fb995500ae68849458ee10d66abbdcfb252;hp=62260a2e23812cbe661495166d1a52a8865ef447;hpb=a2bd1bf0c2c1f1a17d188f4dc0726a45494cefae;p=yaffs-website diff --git a/web/core/lib/Drupal/Core/Plugin/DefaultPluginManager.php b/web/core/lib/Drupal/Core/Plugin/DefaultPluginManager.php index 62260a2e2..c74fcbe95 100644 --- a/web/core/lib/Drupal/Core/Plugin/DefaultPluginManager.php +++ b/web/core/lib/Drupal/Core/Plugin/DefaultPluginManager.php @@ -2,6 +2,7 @@ namespace Drupal\Core\Plugin; +use Drupal\Component\Assertion\Inspector; use Drupal\Component\Plugin\Definition\PluginDefinitionInterface; use Drupal\Component\Plugin\Discovery\CachedDiscoveryInterface; use Drupal\Core\Cache\CacheableDependencyInterface; @@ -148,14 +149,14 @@ class DefaultPluginManager extends PluginManagerBase implements PluginManagerInt * definitions should be cleared along with other, related cache entries. */ public function setCacheBackend(CacheBackendInterface $cache_backend, $cache_key, array $cache_tags = []) { - assert('\Drupal\Component\Assertion\Inspector::assertAllStrings($cache_tags)', 'Cache Tags must be strings.'); + assert(Inspector::assertAllStrings($cache_tags), 'Cache Tags must be strings.'); $this->cacheBackend = $cache_backend; $this->cacheKey = $cache_key; $this->cacheTags = $cache_tags; } /** - * Initializes the alter hook. + * Sets the alter hook name. * * @param string $alter_hook * Name of the alter hook; for example, to invoke