Skip to content

Commit 4bca26d

Browse files
committed
DI: fixed generating proies like in nettrine/orm =< v0.9
1 parent e840349 commit 4bca26d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/DI/OrmExtension.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ public function getConfigSchema(): Schema
8585
{
8686
$parameters = $this->getContainerBuilder()->parameters;
8787
$proxyDir = isset($parameters['tempDir']) ? $parameters['tempDir'] . '/cache/doctrine/orm/proxies' : null;
88-
$autoGenerateProxy = boolval($parameters['debugMode'] ?? true);
88+
$autoGenerateProxy = Expect::anyOf(Expect::int(), Expect::bool(), Expect::type(Statement::class))->default(2); // 2 is Doctrine\Common\Proxy\AbstractProxyFactory::AUTOGENERATE_FILE_NOT_EXISTS
8989

9090
$expectService = Expect::anyOf(
9191
Expect::string()->required()->assert(fn ($input) => str_starts_with($input, '@') || class_exists($input) || interface_exists($input)),

0 commit comments

Comments
 (0)