Fixed bug if a complex type contains a collection
This commit is contained in:
@ -98,6 +98,12 @@ class RpcLiteralRequestMessageBinder implements MessageBinderInterface
|
||||
|
||||
$value = $this->processType($type->getValue(), $value);
|
||||
|
||||
if ($p->isPublic()) {
|
||||
$message->{$type->getName()} = $value;
|
||||
} else {
|
||||
$p->setValue($message, $value);
|
||||
}
|
||||
|
||||
if (!$type->isNillable() && null === $value) {
|
||||
throw new \SoapFault('SOAP_ERROR_COMPLEX_TYPE', sprintf('"%s:%s" cannot be null.', ucfirst(Wsdl::translateType($phpType)), $type->getName()));
|
||||
}
|
||||
|
@ -76,13 +76,17 @@ class RpcLiteralResponseMessageBinder implements MessageBinderInterface
|
||||
$p = $r->getProperty($type->getName());
|
||||
if ($p->isPublic()) {
|
||||
$value = $message->{$type->getName()};
|
||||
|
||||
$message->{$type->getName()} = $this->processType($type->getValue(), $value);
|
||||
} else {
|
||||
$p->setAccessible(true);
|
||||
$value = $p->getValue($message);
|
||||
}
|
||||
|
||||
$p->setValue($message, $this->processType($type->getValue(), $value));
|
||||
$value = $this->processType($type->getValue(), $value);
|
||||
|
||||
if ($p->isPublic()) {
|
||||
$message->{$type->getName()} = $value;
|
||||
} else {
|
||||
$p->setValue($message, $value);
|
||||
}
|
||||
|
||||
if (!$type->isNillable() && null === $value) {
|
||||
@ -92,4 +96,4 @@ class RpcLiteralResponseMessageBinder implements MessageBinderInterface
|
||||
|
||||
return $message;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user