Open tjpeden opened 4 years ago
Thanks for letting us know @tjpeden - we'll take a look.
@tyduptyler13 was unable to recreate, but we've re-worked some of the error handling and added some additional type information.
See if you can still recreate at 1.13.2 https://www.npmjs.com/package/@fusionauth/typescript-client
@tjpeden Have you been able to reproduce with client versions >= 1.13.2 ?
@tyduptyler13 @robotdan the change introduced by this commit isn't working for me in the browser. There's never a response.body, even for a normal 200 response (with a body). I also don't see that property on the response object with console.dir. I checked in both FF DE 72 and Chromium 79. I assume this is working for @tyduptyler13 because it was tested in Node.JS and the node-fetch implementation already includes the
body
property, but browser support isn't there.My understanding of the it was written before my chance and the way I wrote my change is that if there was no body, it would (as @tyduptyler13 said) throw an error, which would be caught and stored in clientResponse.exception which if clientResponse.wasSuccessful() returns true, could safely be ignored.