Skip to content

Commit 6f62ee9

Browse files
committed
MCP-797: Getting error while running performance tool
1 parent efa6c6f commit 6f62ee9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

setup/src/Magento/Setup/Module/Di/Code/Scanner/PhpScanner.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ private function findMissingFactories($file, $classReflection, $methodName, $ent
6262
$parameters = $constructor->getParameters();
6363
/** @var $parameter \ReflectionParameter */
6464
foreach ($parameters as $parameter) {
65-
preg_match('/\[\s\<\w+?>\s([\w\\\\]+)/s', $parameter->__toString(), $matches);
65+
preg_match('/\[\s\<\w+?>\s\??([\w\\\\]+)/s', $parameter->__toString(), $matches);
6666
if (isset($matches[1]) && substr($matches[1], -strlen($entityType)) == $entityType) {
6767
$missingClassName = $matches[1];
6868
if ($this->shouldGenerateClass($missingClassName, $entityType, $file)) {

0 commit comments

Comments
 (0)