mirror of
https://github.com/rclone/rclone.git
synced 2024-12-23 15:38:57 +01:00
d35673efc6
When we run MKCOL on 4shared on a directory that already exists, this returns a 409/Conflict error. However this error code usually means that the intermediate collections need creating. The actual error code to return when trying to create a directory that already exists isn't specified in the RFC, only that an error MUST be returned and there are already 3 statuses checked in the code. However using 409 makes rclone's usual strategy for making directories fail and return the 409 error. This patch tries the MKCOL and if it returns an unrecognised error code, then calls PROPFIND on the directory to discover whether the directory really exists or not. This should also cover other WebDAV servers returning other error messages we haven't accounted for in the code yet. |
||
---|---|---|
.. | ||
api | ||
odrvcookie | ||
webdav_test.go | ||
webdav.go |