You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The PUT handler doesn't match the semantics of the traditional PUT verb.
I chose PUT because I wanted a way for the client to signal to the server that it wanted back the URL instead of a JSON object.
Revisiting the decision, I should have just used an Accept header in the request to let the client specify whether they want plaintext (default) or JSON. So we should combine the handlers for PUT and POST into a single handler that chooses output based on the content type and accept headers.
The
PUT
handler doesn't match the semantics of the traditionalPUT
verb.I chose
PUT
because I wanted a way for the client to signal to the server that it wanted back the URL instead of a JSON object.Revisiting the decision, I should have just used an
Accept
header in the request to let the client specify whether they want plaintext (default) or JSON. So we should combine the handlers forPUT
andPOST
into a single handler that chooses output based on the content type and accept headers.See similar work in PicoShare: https://github.com/mtlynch/picoshare/pull/318/files
The text was updated successfully, but these errors were encountered: