As suggested in #311, Naja expects responses to be JSON, so it makes sense to formalize this expectation via the Accept header:
Accept: application/json, sure, why not, Naja expects JSON anyway and breaks if anything else is returned. I'd say it should even be hardcoded the same way that X-Requested-With is. PRs welcome :wink:
As suggested in #311, Naja expects responses to be JSON, so it makes sense to formalize this expectation via the
Accept
header: