amnong / easywebdav

A WebDAV Client in Python
http://pypi.python.org/pypi/easywebdav/
ISC License
207 stars 113 forks source link

Added 200 to ok results for PUT action #22

Closed KillerX closed 10 years ago

KillerX commented 10 years ago

The server im working with is returning status 200 for successful PUT request. This also seems in accordance with http://www.w3.org/Protocols/rfc2616/rfc2616-sec9.html stating in section 9.6:

If a new resource is created, the origin server MUST inform the user agent via the 201 (Created) response. If an existing resource is modified, either the 200 (OK) or 204 (No Content) response codes SHOULD be sent to indicate successful completion of the request. If the resource could not be created or modified with the Request-URI, an appropriate error response SHOULD be given that reflects the nature of the problem.

This patch simply adds the return code 200 to be accepted as success when PUTing things.

glader commented 10 years ago

:+1:

amnong commented 10 years ago

To avoid conflicts, I fixed this manually.