Skip to content

Commit 800ea00

Browse files
Dominik Zoggfabpot
authored andcommitted
without this change allways the legacy code get called
1 parent 5ec7892 commit 800ea00

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

Extension/Validator/ValidatorExtension.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -59,13 +59,13 @@ public function __construct($validator)
5959

6060
public function loadTypeGuesser()
6161
{
62-
// 2.4 API
63-
if ($this->validator instanceof LegacyValidatorInterface) {
64-
return new ValidatorTypeGuesser($this->validator->getMetadataFactory());
62+
// 2.5 API
63+
if ($this->validator instanceof ValidatorInterface) {
64+
return new ValidatorTypeGuesser($this->validator);
6565
}
6666

67-
// 2.5 API - ValidatorInterface extends MetadataFactoryInterface
68-
return new ValidatorTypeGuesser($this->validator);
67+
// 2.4 API
68+
return new ValidatorTypeGuesser($this->validator->getMetadataFactory());
6969
}
7070

7171
protected function loadTypeExtensions()

0 commit comments

Comments
 (0)