Skip to content

Commit 4013968

Browse files
committed
Unconfigure enable_native_lazy_objects on Doctrine Bundle >= 4
1 parent be07cf1 commit 4013968

File tree

3 files changed

+5
-3
lines changed

3 files changed

+5
-3
lines changed

src/Autocomplete/tests/Fixtures/Kernel.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,8 @@ protected function configureContainer(ContainerConfigurator $c): void
138138
$doctrineConfig['orm']['controller_resolver']['auto_mapping'] = true;
139139
}
140140
}
141-
if (\PHP_VERSION_ID >= 80400 && version_compare($doctrineBundleVersion, '2.15.0', '>=')) {
141+
142+
if (\PHP_VERSION_ID >= 80400 && version_compare($doctrineBundleVersion, '2.15.0', '>=') && version_compare($doctrineBundleVersion, '4.0.0', '<')) {
142143
$doctrineConfig['orm']['enable_native_lazy_objects'] = true;
143144
}
144145
}

src/LiveComponent/tests/Fixtures/Kernel.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -201,7 +201,8 @@ protected function configureContainer(ContainerConfigurator $c): void
201201
$doctrineConfig['orm']['validate_xml_mapping'] = true;
202202
$doctrineConfig['dbal']['schema_manager_factory'] = 'doctrine.dbal.default_schema_manager_factory';
203203
}
204-
if (\PHP_VERSION_ID >= 80400 && version_compare($doctrineBundleVersion, '2.15.0', '>=')) {
204+
205+
if (\PHP_VERSION_ID >= 80400 && version_compare($doctrineBundleVersion, '2.15.0', '>=') && version_compare($doctrineBundleVersion, '4.0.0', '<')) {
205206
$doctrineConfig['orm']['enable_native_lazy_objects'] = true;
206207
}
207208
}

src/Turbo/tests/app/Kernel.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ protected function configureContainer(ContainerConfigurator $container): void
111111
}
112112
}
113113

114-
if (\PHP_VERSION_ID >= 80400 && version_compare($doctrineBundleVersion, '2.15.0', '>=')) {
114+
if (\PHP_VERSION_ID >= 80400 && version_compare($doctrineBundleVersion, '2.15.0', '>=') && version_compare($doctrineBundleVersion, '4.0.0', '<')) {
115115
$doctrineConfig['orm']['enable_native_lazy_objects'] = true;
116116
}
117117
}

0 commit comments

Comments
 (0)