http://drupal.org/project/uc_clickandbuy relies on this module to handle some transactions with ClickandBuy servers. It needs the return data from a SOAP call in a consistent format so it calls soapclient_object_to_array() which was present in the 6.x-1.0-beta2 release but has been removed recently in the updates on the -dev branch. A patch is attached that re-adds this function.

I still have commit access to this project but figured I should post a patch first as the module is currently under active development.

CommentFileSizeAuthor
soapclient_object_to_array.patch852 byteslongwave

Comments

ilo’s picture

Just considering this..

I wonder how a module depends on other to convert an object into an array. I'd suggest to request this operation to be done by uc_clickandbuy, it makes more sense as long as it is that module requiring an array, than to have a generic function (object to array conversion) in this module just because other module needs this conversion..

what do you think?

longwave’s picture

I seem to remember the inconsistency happens because the result is formatted slightly differently (nested arrays vs nested objects) depending on whether you use the PHP5 SOAP extension or NuSOAP, so I think this should be SOAP Client's responsibility to return consistent data from either handler. I guess I'll have to go back and do some testing to figure out why I needed that call in the first place.

ilo’s picture

As you said, you are still granted with cvs access, so you can put the function back, having in mind the reason why I just removed it. Sorry if that caused any inconvenience.

longwave’s picture

It will only become a real problem when a new release of SOAP Client is made, as currently the existing stable release works successfully with uc_clickandbuy. I will leave this issue open for now until I find time to do some tests with the updated SOAP Client module.