laravel
laravel copied to clipboard
Delete `Accept` header is not checked for compliance with JSON:API
When fixing #184 I've realised there's no checking of the Accept media type in the destroy controller action. The JSON:API specification shows that a DELETE request should have an Accept: application/vnd.api+json header, as shown in this example:
https://jsonapi.org/format/#crud-deleting
We need to add this, however I'd consider this a breaking change - because at the moment people may have set up clients to not send the Accept header. So this should be fixed for 3.0.
This is done, issue will close when 3.x is merged to develop.
Closing this as 3.0 will be tagged soon for Laravel 10.