Fixed issue #29

This commit is contained in:
Francis Besset
2013-02-27 17:06:00 +01:00
parent a50215b649
commit ea4d031084
2 changed files with 20 additions and 0 deletions

View File

@ -61,6 +61,16 @@ class RpcLiteralRequestMessageBinder implements MessageBinderInterface
foreach ($message->item as $complexType) {
$array[] = $this->checkComplexType($phpType, $complexType);
}
// See https://github.com/BeSimple/BeSimpleSoapBundle/issues/29
if (in_array('BeSimple\SoapCommon\Type\AbstractKeyValue', class_parents($phpType))) {
$assocArray = array();
foreach ($array as $keyValue) {
$assocArray[$keyValue->getKey()] = $keyValue->getValue();
}
$array = $assocArray;
}
}
$message = $array;