[DI] fix
This commit is contained in:
parent
03b9ff177d
commit
d2efe50eee
@ -23,7 +23,8 @@ class InvalidParameterTypeException extends InvalidArgumentException
|
||||
{
|
||||
$acceptedType = $parameter->getType();
|
||||
$acceptedType = $acceptedType instanceof \ReflectionNamedType ? $acceptedType->getName() : (string) $acceptedType;
|
||||
$this->code = $type;
|
||||
|
||||
parent::__construct(sprintf('Invalid definition for service "%s": argument %d of "%s::%s" accepts "%s", "%s" passed.', $serviceId, 1 + $parameter->getPosition(), $parameter->getDeclaringClass()->getName(), $parameter->getDeclaringFunction()->getName(), $acceptedType, $type), $type);
|
||||
parent::__construct(sprintf('Invalid definition for service "%s": argument %d of "%s::%s" accepts "%s", "%s" passed.', $serviceId, 1 + $parameter->getPosition(), $parameter->getDeclaringClass()->getName(), $parameter->getDeclaringFunction()->getName(), $acceptedType, $type));
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user