mirror of
https://github.com/drakkan/sftpgo.git
synced 2026-03-14 14:25:52 +01:00
fix: Implement Kopiermonster webdev dialect by returning 200 OK to GET requests
This commit is contained in:
parent
fbf8b1285d
commit
0338eade59
1 changed files with 3 additions and 2 deletions
|
|
@ -249,11 +249,12 @@ func (s *webDavServer) ServeHTTP(w http.ResponseWriter, r *http.Request) {
|
|||
|
||||
dataprovider.UpdateLastLogin(&user)
|
||||
|
||||
// Kopiermonster speaks a 'special' webdav dialect and ceases working if we send a non-200 status code.
|
||||
if s.checkRequestMethod(ctx, r, connection) {
|
||||
w.Header().Set("Content-Type", "text/xml; charset=utf-8")
|
||||
w.WriteHeader(http.StatusMultiStatus)
|
||||
w.WriteHeader(http.StatusOK)
|
||||
w.Write([]byte("")) //nolint:errcheck
|
||||
writeLog(r, http.StatusMultiStatus, nil)
|
||||
writeLog(r, http.StatusOK, nil)
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue