fix use of deprecated methods

This commit is contained in:
sunxyw
2022-05-15 16:40:12 +08:00
parent 24a213a8ff
commit 4f10b6dbc3
2 changed files with 2 additions and 2 deletions

View File

@@ -663,7 +663,7 @@ trait ContainerTrait
{
try {
// 尝试解析
return $this->make($parameter->getClass()->name);
return $this->make(ReflectionUtil::getParameterClassName($parameter));
} catch (EntryResolutionException $e) {
// 如果参数是可选的,则返回默认值
if ($parameter->isDefaultValueAvailable()) {