You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: DependencyInjection/FrameworkExtension.php
+18-18Lines changed: 18 additions & 18 deletions
Original file line number
Diff line number
Diff line change
@@ -232,7 +232,7 @@ public function load(array $configs, ContainerBuilder $container)
232
232
// default in the Form and Validator component). If disabled, an identity
233
233
// translator will be used and everything will still work as expected.
234
234
if ($this->isConfigEnabled($container, $config['translator']) || $this->isConfigEnabled($container, $config['form']) || $this->isConfigEnabled($container, $config['validation'])) {
235
-
if (!class_exists('Symfony\Component\Translation\Translator') && $this->isConfigEnabled($container, $config['translator'])) {
235
+
if (!class_exists(Translator::class) && $this->isConfigEnabled($container, $config['translator'])) {
236
236
thrownewLogicException('Translation support cannot be enabled as the Translation component is not installed. Try running "composer require symfony/translation".');
237
237
}
238
238
@@ -320,14 +320,14 @@ public function load(array $configs, ContainerBuilder $container)
if ($this->isConfigEnabled($container, $config['serializer'])) {
411
-
if (!class_exists('Symfony\Component\Serializer\Serializer')) {
411
+
if (!class_exists(\Symfony\Component\Serializer\Serializer::class)) {
412
412
thrownewLogicException('Serializer support cannot be enabled as the Serializer component is not installed. Try running "composer require symfony/serializer-pack".');
413
413
}
414
414
@@ -1170,18 +1170,18 @@ private function registerTranslatorConfiguration(array $config, ContainerBuilder
1170
1170
$dirs = [];
1171
1171
$transPaths = [];
1172
1172
$nonExistingDirs = [];
1173
-
if (class_exists('Symfony\Component\Validator\Validation')) {
1174
-
$r = new \ReflectionClass('Symfony\Component\Validator\Validation');
1173
+
if (class_exists(\Symfony\Component\Validator\Validation::class)) {
1174
+
$r = new \ReflectionClass(\Symfony\Component\Validator\Validation::class);
@@ -1279,7 +1279,7 @@ private function registerValidationConfiguration(array $config, ContainerBuilder
1279
1279
return;
1280
1280
}
1281
1281
1282
-
if (!class_exists('Symfony\Component\Validator\Validation')) {
1282
+
if (!class_exists(\Symfony\Component\Validator\Validation::class)) {
1283
1283
thrownewLogicException('Validation support cannot be enabled as the Validator component is not installed. Try running "composer require symfony/validator".');
1284
1284
}
1285
1285
@@ -1346,8 +1346,8 @@ private function registerValidatorMapping(ContainerBuilder $container, array $co
@@ -1408,7 +1408,7 @@ private function registerAnnotationsConfiguration(array $config, ContainerBuilde
1408
1408
return;
1409
1409
}
1410
1410
1411
-
if (!class_exists('Doctrine\Common\Annotations\Annotation')) {
1411
+
if (!class_exists(\Doctrine\Common\Annotations\Annotation::class)) {
1412
1412
thrownewLogicException('Annotations cannot be enabled as the Doctrine Annotation library is not installed.');
1413
1413
}
1414
1414
@@ -1420,7 +1420,7 @@ private function registerAnnotationsConfiguration(array $config, ContainerBuilde
1420
1420
}
1421
1421
1422
1422
if ('none' !== $config['cache']) {
1423
-
if (!class_exists('Doctrine\Common\Cache\CacheProvider')) {
1423
+
if (!class_exists(\Doctrine\Common\Cache\CacheProvider::class)) {
1424
1424
thrownewLogicException('Annotations cannot be enabled as the Doctrine Cache library is not installed.');
1425
1425
}
1426
1426
@@ -1531,7 +1531,7 @@ private function registerSecurityCsrfConfiguration(array $config, ContainerBuild
1531
1531
return;
1532
1532
}
1533
1533
1534
-
if (!class_exists('Symfony\Component\Security\Csrf\CsrfToken')) {
1534
+
if (!class_exists(\Symfony\Component\Security\Csrf\CsrfToken::class)) {
1535
1535
thrownewLogicException('CSRF support cannot be enabled as the Security CSRF component is not installed. Try running "composer require symfony/security-csrf".');
1536
1536
}
1537
1537
@@ -1646,7 +1646,7 @@ private function registerPropertyInfoConfiguration(ContainerBuilder $container,
1646
1646
1647
1647
$loader->load('property_info.php');
1648
1648
1649
-
if (interface_exists('phpDocumentor\Reflection\DocBlockFactoryInterface')) {
1649
+
if (interface_exists(\phpDocumentor\Reflection\DocBlockFactoryInterface::class)) {
0 commit comments