1 | <?php |
||
2 | |||
3 | use Doctrine\ORM\Mapping\ClassMetadata; |
||
4 | use Doctrine\ORM\Mapping\ClassMetadataInfo; |
||
0 ignored issues
–
show
|
|||
5 | |||
6 | spl_autoload_register(function ($class) : void { |
||
7 | $deprecatedClasses = [ |
||
8 | ClassMetadataInfo::class => [ClassMetadata::class, '2.7', '3.0'], |
||
9 | ]; |
||
10 | |||
11 | if (array_key_exists($class, $deprecatedClasses)) { |
||
12 | $deprecationMetadata = $deprecatedClasses[$class]; |
||
13 | @trigger_error(sprintf( |
||
14 | 'Class %s is deprecated in favor of class %s since %s, will be removed in %s.', |
||
15 | $class, |
||
16 | ...$deprecationMetadata |
||
17 | ), E_USER_DEPRECATED); |
||
18 | class_alias($deprecationMetadata[0], $class); |
||
19 | } |
||
20 | }); |
||
21 |
The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g.
excluded_paths: ["lib/*"]
, you can move it to the dependency path list as follows:For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths