modify
This commit is contained in:
@@ -178,9 +178,9 @@ class Container extends BaseObject
|
|||||||
} else {
|
} else {
|
||||||
$reflection = $this->_reflection[$class];
|
$reflection = $this->_reflection[$class];
|
||||||
}
|
}
|
||||||
// if (!is_null($construct = $reflection->getConstructor())) {
|
if (!is_null($construct = $reflection->getConstructor())) {
|
||||||
// $constrict = $this->resolveMethodParam($construct);
|
$constrict = $this->resolveMethodParam($construct);
|
||||||
// }
|
}
|
||||||
return [$reflection, $constrict];
|
return [$reflection, $constrict];
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -195,9 +195,7 @@ class Container extends BaseObject
|
|||||||
{
|
{
|
||||||
$array = [];
|
$array = [];
|
||||||
foreach ($method->getParameters() as $key => $parameter) {
|
foreach ($method->getParameters() as $key => $parameter) {
|
||||||
if (version_compare(PHP_VERSION, '5.6.0', '>=') && $parameter->isVariadic()) {
|
if ($parameter->isDefaultValueAvailable()) {
|
||||||
break;
|
|
||||||
} else if ($parameter->isDefaultValueAvailable()) {
|
|
||||||
$array[] = $parameter->getDefaultValue();
|
$array[] = $parameter->getDefaultValue();
|
||||||
} else {
|
} else {
|
||||||
$type = $parameter->getType();
|
$type = $parameter->getType();
|
||||||
|
|||||||
Reference in New Issue
Block a user