Skip to content

Commit 116805d

Browse files
author
Stanislav Idolov
authored
ENGCOM-1540: Adding support for variadic arguments' method in generated proxy c… #15177
2 parents 99d33d3 + 082fce0 commit 116805d

File tree

1 file changed

+2
-1
lines changed
  • lib/internal/Magento/Framework/ObjectManager/Code/Generator

1 file changed

+2
-1
lines changed

lib/internal/Magento/Framework/ObjectManager/Code/Generator/Proxy.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,8 @@ protected function _getMethodInfo(\ReflectionMethod $method)
155155
$parameterNames = [];
156156
$parameters = [];
157157
foreach ($method->getParameters() as $parameter) {
158-
$parameterNames[] = '$' . $parameter->getName();
158+
$name = $parameter->isVariadic() ? '... $' . $parameter->getName() : '$' . $parameter->getName();
159+
$parameterNames[] = $name;
159160
$parameters[] = $this->_getMethodParameterInfo($parameter);
160161
}
161162

0 commit comments

Comments
 (0)