I agree.
self.lastResponseHeaders = response && response.headers;
is good.
When I suggested to move up the if(err) I had in front of me a version that
had self.lastResponseHeaders = response.headers, that broke when there was
no response.


On Sat, May 24, 2014 at 1:16 PM, Christiaan Westerbeek <
notifications@github.com> wrote:

> In lib/client.js:
>
> >      if (err) {
> >        callback(err);
> >      } else {
> > +      self.lastResponse = body;
>
> If there was an error but also a response. The most intuitive for the user
> would be to put that response in lastResponse. - sent from my mobile phone
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/vpulim/node-soap/pull/265/files#r13025768>
> .
>