Skip to content
This repository was archived by the owner on Mar 13, 2018. It is now read-only.

make handleAs ignore response body for status code 204 #49

Open
tostrowski opened this issue Nov 17, 2014 · 1 comment
Open

make handleAs ignore response body for status code 204 #49

tostrowski opened this issue Nov 17, 2014 · 1 comment

Comments

@tostrowski
Copy link

When response is 204 and handleAs="json" then core-ajax still tries to parse response body which results in SyntaxError: Unexpected end of input {stack: (...), message: "Unexpected end of input"}
Maybe it could set response field to undefined instead.

@DavidLGoldberg
Copy link

Should fire an error no?

More opinions:
http://stackoverflow.com/questions/11970962/valid-json-in-response

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants