| 1 | <?php |
||
| 10 | class Validator |
||
| 11 | { |
||
| 12 | use SymfonyAssertsTrait; |
||
| 13 | |||
| 14 | /** @var SchemaManager */ |
||
| 15 | private $schemaManager; |
||
| 16 | |||
| 17 | /** @var bool */ |
||
| 18 | private $strict; |
||
| 19 | |||
| 20 | /** @var Factory */ |
||
| 21 | private $constraintsFactory; |
||
| 22 | |||
| 23 | 4 | public function __construct(Factory $constraintsFactory, SchemaManager $schemaManager, $strict) |
|
| 29 | |||
| 30 | 4 | public function validate(Request $request) |
|
| 40 | |||
| 41 | /** |
||
| 42 | * @return SchemaManager |
||
| 43 | */ |
||
| 44 | public function getSchemaManager() |
||
| 48 | |||
| 49 | /** |
||
| 50 | * {@inheritdoc} |
||
| 51 | */ |
||
| 52 | 2 | protected function getValidator() |
|
| 56 | } |
||
| 57 |
It seems like the type of the argument is not accepted by the function/method which you are calling.
In some cases, in particular if PHP’s automatic type-juggling kicks in this might be fine. In other cases, however this might be a bug.
We suggest to add an explicit type cast like in the following example: