mirror of
https://github.com/zhamao-robot/zhamao-framework.git
synced 2026-07-24 09:05:34 +08:00
fix use of deprecated methods
This commit is contained in:
@@ -4,10 +4,10 @@ parameters:
|
|||||||
paths:
|
paths:
|
||||||
- ./src/
|
- ./src/
|
||||||
ignoreErrors:
|
ignoreErrors:
|
||||||
- '#Used constant OS_TYPE_(LINUX|WINDOWS) not found#'
|
|
||||||
- '#Constant .* not found#'
|
- '#Constant .* not found#'
|
||||||
- '#PHPDoc tag @throws with type Psr\\Container\\ContainerExceptionInterface is not subtype of Throwable#'
|
- '#PHPDoc tag @throws with type Psr\\Container\\ContainerExceptionInterface is not subtype of Throwable#'
|
||||||
- '#Unsafe usage of new static#'
|
- '#Unsafe usage of new static#'
|
||||||
|
- '#Call to method initTableList\(\) of deprecated class ZM\\DB\\DB#'
|
||||||
dynamicConstantNames:
|
dynamicConstantNames:
|
||||||
- SWOOLE_VERSION
|
- SWOOLE_VERSION
|
||||||
- ZM_TEST_LOG_DEBUG
|
- ZM_TEST_LOG_DEBUG
|
||||||
|
|||||||
@@ -663,7 +663,7 @@ trait ContainerTrait
|
|||||||
{
|
{
|
||||||
try {
|
try {
|
||||||
// 尝试解析
|
// 尝试解析
|
||||||
return $this->make($parameter->getClass()->name);
|
return $this->make(ReflectionUtil::getParameterClassName($parameter));
|
||||||
} catch (EntryResolutionException $e) {
|
} catch (EntryResolutionException $e) {
|
||||||
// 如果参数是可选的,则返回默认值
|
// 如果参数是可选的,则返回默认值
|
||||||
if ($parameter->isDefaultValueAvailable()) {
|
if ($parameter->isDefaultValueAvailable()) {
|
||||||
|
|||||||
Reference in New Issue
Block a user