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
@@ -635,6 +636,10 @@ private function registerJsonApiConfiguration(array $formats, PhpFileLoader $loa
635
636
return;
636
637
}
637
638
639
+
if (!InstalledVersions::isInstalled('api-platform/json-api')) {
640
+
thrownew \LogicException('JSON-API support cannot be enabled as the JSON-API component is not installed. Try running "composer require api-platform/json-api".');
641
+
}
642
+
638
643
$loader->load('jsonapi.php');
639
644
$loader->load('state/jsonapi.php');
640
645
}
@@ -666,6 +671,10 @@ private function registerJsonHalConfiguration(array $formats, PhpFileLoader $loa
666
671
return;
667
672
}
668
673
674
+
if (!InstalledVersions::isInstalled('api-platform/hal')) {
675
+
thrownew \LogicException('HAL support cannot be enabled as the HAL component is not installed. Try running "composer require api-platform/hal".');
676
+
}
677
+
669
678
$loader->load('hal.php');
670
679
}
671
680
@@ -738,6 +747,10 @@ private function registerDoctrineOrmConfiguration(ContainerBuilder $container, a
738
747
return;
739
748
}
740
749
750
+
if (!InstalledVersions::isInstalled('api-platform/doctrine-orm')) {
751
+
thrownew \LogicException('Doctrine support cannot be enabled as the doctrine ORM component is not installed. Try running "composer require api-platform/doctrine-orm".');
752
+
}
753
+
741
754
// For older versions of doctrine bridge this allows autoconfiguration for filters
@@ -770,6 +783,10 @@ private function registerDoctrineMongoDbOdmConfiguration(ContainerBuilder $conta
770
783
return;
771
784
}
772
785
786
+
if (!InstalledVersions::isInstalled('api-platform/doctrine-odm')) {
787
+
thrownew \LogicException('Doctrine MongoDB ODM support cannot be enabled as the doctrine ODM component is not installed. Try running "composer require api-platform/doctrine-odm".');
@@ -879,6 +896,10 @@ private function registerMercureConfiguration(ContainerBuilder $container, array
879
896
return;
880
897
}
881
898
899
+
if (!InstalledVersions::isInstalled('symfony/mercure-bundle')) {
900
+
thrownew \LogicException('Mercure support cannot be enabled as the Symfony Mercure Bundle is not installed. Try running "composer require symfony/mercure-bundle".');
@@ -900,6 +921,10 @@ private function registerMessengerConfiguration(ContainerBuilder $container, arr
900
921
return;
901
922
}
902
923
924
+
if (!InstalledVersions::isInstalled('symfony/messenger')) {
925
+
thrownew \LogicException('Messenger support cannot be enabled as the Symfony Messenger component is not installed. Try running "composer require symfony/messenger".');
926
+
}
927
+
903
928
$loader->load('messenger.php');
904
929
}
905
930
@@ -913,6 +938,10 @@ private function registerElasticsearchConfiguration(ContainerBuilder $container,
913
938
return;
914
939
}
915
940
941
+
if (!InstalledVersions::isInstalled('api-platform/elasticsearch')) {
942
+
thrownew \LogicException('Elasticsearch support cannot be enabled as the Elasticsearch component is not installed. Try running "composer require api-platform/elasticsearch".');
0 commit comments