File tree Expand file tree Collapse file tree 8 files changed +19
-22
lines changed
Expand file tree Collapse file tree 8 files changed +19
-22
lines changed Original file line number Diff line number Diff line change 2323 "willdurand/geocoder" : " ^4.6|^5.0"
2424 },
2525 "require-dev" : {
26- "doctrine/doctrine-bundle" : " ^2.3 " ,
26+ "doctrine/doctrine-bundle" : " ^2.18 || ^3.0 " ,
2727 "doctrine/orm" : " ^2.20 || ^3.0" ,
2828 "fakerphp/faker" : " ^1.20" ,
2929 "friendsofphp/php-cs-fixer" : " ^3.13" ,
Original file line number Diff line number Diff line change @@ -41,10 +41,8 @@ class BazingaGeocoderExtension extends Extension
4141{
4242 /**
4343 * @param array<mixed, mixed> $configs
44- *
45- * @return void
4644 */
47- public function load (array $ configs , ContainerBuilder $ container )
45+ public function load (array $ configs , ContainerBuilder $ container ): void
4846 {
4947 $ processor = new Processor ();
5048 $ configuration = $ this ->getConfiguration ($ configs , $ container );
Original file line number Diff line number Diff line change @@ -25,10 +25,8 @@ class AddProvidersPass implements CompilerPassInterface
2525 /**
2626 * Get all providers based on their tag (`bazinga_geocoder.provider`) and
2727 * register them.
28- *
29- * @return void
3028 */
31- public function process (ContainerBuilder $ container )
29+ public function process (ContainerBuilder $ container ): void
3230 {
3331 if (!$ container ->hasDefinition (ProviderAggregator::class)) {
3432 return ;
Original file line number Diff line number Diff line change @@ -28,10 +28,7 @@ class FactoryValidatorPass implements CompilerPassInterface
2828 */
2929 private static $ factoryServiceIds = [];
3030
31- /**
32- * @return void
33- */
34- public function process (ContainerBuilder $ container )
31+ public function process (ContainerBuilder $ container ): void
3532 {
3633 foreach (self ::$ factoryServiceIds as $ id ) {
3734 if (!$ container ->hasAlias ($ id ) && !$ container ->hasDefinition ($ id )) {
Original file line number Diff line number Diff line change 2424 */
2525class ProfilerPass implements CompilerPassInterface
2626{
27- /**
28- * @return void
29- */
30- public function process (ContainerBuilder $ container )
27+ public function process (ContainerBuilder $ container ): void
3128 {
3229 if (!$ container ->hasDefinition (GeocoderDataCollector::class)) {
3330 return ;
Original file line number Diff line number Diff line change @@ -31,7 +31,7 @@ public function isGeocodeable(object $object): bool
3131 }
3232
3333 /**
34- * @throws MappingException
34+ * @throws MappingException|\ReflectionException
3535 */
3636 public function loadMetadataFromObject (object $ object ): ClassMetadata
3737 {
@@ -76,6 +76,8 @@ public function loadMetadataFromObject(object $object): ClassMetadata
7676 * @param T $object
7777 *
7878 * @return \ReflectionClass<T>
79+ *
80+ * @throws \ReflectionException
7981 */
8082 private static function getReflection (object $ object ): \ReflectionClass
8183 {
@@ -84,7 +86,12 @@ private static function getReflection(object $object): \ReflectionClass
8486 return ClassUtils::newReflectionObject ($ object );
8587 }
8688
89+ if (PHP_VERSION_ID < 80400 ) {
90+ /** @var \ReflectionClass<T> */
91+ return new \ReflectionClass (DefaultProxyClassNameResolver::getClass ($ object ));
92+ }
93+
8794 /** @var \ReflectionClass<T> */
88- return new \ReflectionClass (DefaultProxyClassNameResolver:: getClass ( $ object) );
95+ return new \ReflectionClass ($ object );
8996 }
9097}
Original file line number Diff line number Diff line change @@ -71,14 +71,14 @@ public function process(ContainerBuilder $container): void
7171 $ kernel ->addTestConfig (static function (ContainerBuilder $ container ) {
7272 $ container ->prependExtensionConfig ('doctrine ' , [
7373 'orm ' => [
74- 'report_fields_where_declared ' => true ,
74+ // 'report_fields_where_declared' => true,
7575 ],
7676 ]);
7777
7878 if (method_exists (Configuration::class, 'setLazyGhostObjectEnabled ' ) && Kernel::VERSION_ID >= 60100 ) {
7979 $ container ->prependExtensionConfig ('doctrine ' , [
8080 'orm ' => [
81- 'enable_lazy_ghost_objects ' => true ,
81+ // 'enable_lazy_ghost_objects' => true,
8282 ],
8383 ]);
8484 }
@@ -87,7 +87,7 @@ public function process(ContainerBuilder $container): void
8787 $ container ->prependExtensionConfig ('doctrine ' , [
8888 'orm ' => [
8989 'controller_resolver ' => [
90- 'auto_mapping ' => false ,
90+ // 'auto_mapping' => false,
9191 ],
9292 ],
9393 ]);
Original file line number Diff line number Diff line change @@ -6,9 +6,9 @@ doctrine:
66 driver : pdo_sqlite
77 path : ' %kernel.cache_dir%/test.sqlite'
88 orm :
9- auto_generate_proxy_classes : true
9+ # auto_generate_proxy_classes: true
1010 validate_xml_mapping : true
11- report_fields_where_declared : true
11+ # report_fields_where_declared: true
1212 naming_strategy : doctrine.orm.naming_strategy.underscore_number_aware
1313 auto_mapping : false
1414
You can’t perform that action at this time.
0 commit comments