Closed ArbanNichols closed 5 years ago
This is my text/uri list converter that works for me, also for PUT requests. Hope that helps
/**
* MIME type interceptor for our REST client that can handle
* Content-type: "text/uri"
*/
import registry from 'rest/mime/registry'
var uriListConverter = {
read: function (str, opts) {
return str; //MAYBE convert to a array
},
write: function (obj, opts) {
return obj.toString();
}
}
registry.register('text/uri-list', uriListConverter);
rest.js is no longer maintained
I created am using a custom mime converter for the "text/uri-list" content negotiation with a 'PUT' request and the web browser is giving a "mime-serialization" error. The 'PUT' request succeeds using curl.