Skip to content

Commit 2097c9b

Browse files
ENGCOM-1980: Adding support for variadic arguments fro method in generated proxy c… #16081
- Merge Pull Request #16081 from vgelani/magento2:2.1-develop-PR-port-15177 - Merged commits: 1. 7091665
2 parents 477bea4 + 7091665 commit 2097c9b

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)