Benjamin Young created COUCHDB-2882:
---------------------------------------
Summary: Switch to `application/json` from `text/x-json` for
provides()
Key: COUCHDB-2882
URL: https://issues.apache.org/jira/browse/COUCHDB-2882
Project: CouchDB
Issue Type: Bug
Components: HTTP Interface
Reporter: Benjamin Young
{code:javascript}
provides('json', function() {...});
{code}
(which leverages {{registerType()}}'s list of "known" media types) will send
the oldest JSON media type {{text/x-json}} rather than the much more commonly
used {{application/json}}.
The docs for {{registerType()}} shows the list of currently "known" media types:
http://docs.couchdb.org/en/1.6.1/query-server/javascript.html?highlight=provides#registerType
Essentially, the priority needs to be on {{application/json}} unless the server
is asked for {{text/x-json}}.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)