Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Response.to_hash does not work for SOAP Body with more than one child elements #17

Closed
jippeholwerda opened this issue Jan 6, 2010 · 1 comment

Comments

@jippeholwerda
Copy link

If a response body has the following structure:

<?xml version="1.0" encoding="utf-8"?>
<soapenv:Envelope ...>
  <soapenv:Body>
    <ns1:getIssueResponse...>
      <getIssueReturn href="#id0"/>
    </ns1:getIssueResponse>
    <multiRef...>
      ...
    </multiRef...>
    <multiRef...>
      ...
    </multiRef...>
  </soapenv:Body>
</soapenv:Envelope>

then Response.to_hash always returns one child element only, since it only matches the first key. Furthermore, if the first key happens to be multiRef, find_regexp returns an Array. Calling map_soap_response on the Array fails, since that method does not exist.

@rubiii
Copy link
Contributor

rubiii commented Jan 9, 2010

released version 0.7.0 which includes a fix for this problem. instead of returning the content from the "response" element, savon now stops one level above and only returns the content from the "soap:Body" element.

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants