We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 8005333 + 7f40422 commit 6deec36Copy full SHA for 6deec36
src/Configuration.php
@@ -667,15 +667,15 @@ public function isNativeLazyObjectsEnabled(): bool
667
668
public function enableNativeLazyObjects(bool $nativeLazyObjects): void
669
{
670
- if (! $nativeLazyObjects) {
+ if (PHP_VERSION_ID >= 80400 && ! $nativeLazyObjects) {
671
Deprecation::trigger(
672
'doctrine/orm',
673
'https://github.com/doctrine/orm/pull/12005',
674
'Disabling native lazy objects is deprecated and will be impossible in Doctrine ORM 4.0.',
675
);
676
}
677
678
- if (PHP_VERSION_ID < 80400) {
+ if (PHP_VERSION_ID < 80400 && $nativeLazyObjects) {
679
throw new LogicException('Lazy loading proxies require PHP 8.4 or higher.');
680
681
0 commit comments