webdav: add PUT to allowed methods for regular files

This commit is contained in:
Simon Ser 2020-01-21 21:35:37 +01:00
parent 9db481fa51
commit 69f88b075a
No known key found for this signature in database
GPG Key ID: 0FDE7BE0E88F5E48

View File

@ -59,7 +59,13 @@ func (b *backend) Options(r *http.Request) ([]string, error) {
if fi.IsDir() {
return []string{http.MethodOptions, "PROPFIND"}, nil
} else {
return []string{http.MethodOptions, http.MethodHead, http.MethodGet, "PROPFIND"}, nil
return []string{
http.MethodOptions,
http.MethodHead,
http.MethodGet,
http.MethodPut,
"PROPFIND",
}, nil
}
}