mirror of
https://github.com/hacdias/webdav.git
synced 2026-09-22 03:20:41 +08:00
docs: cleanup comments
This commit is contained in:
+4
-4
@@ -146,11 +146,11 @@ func (h *Handler) ServeHTTP(w http.ResponseWriter, r *http.Request) {
|
|||||||
// "index.html" resource, a human-readable view of the contents of
|
// "index.html" resource, a human-readable view of the contents of
|
||||||
// the collection, or something else altogether.
|
// the collection, or something else altogether.
|
||||||
//
|
//
|
||||||
// Similarly, since the definition of HEAD is a GET without a response
|
// Similarly, since the definition of HEAD is a GET without a response
|
||||||
// message body, the semantics of HEAD are unmodified when applied to
|
// message body, the semantics of HEAD are unmodified when applied to
|
||||||
// collection resources.
|
// collection resources.
|
||||||
//
|
//
|
||||||
// Get, when applied to collection, will return the same as PROPFIND method.
|
// GET (or HEAD), when applied to collection, will return the same as PROPFIND method.
|
||||||
if (r.Method == "GET" || r.Method == "HEAD") && strings.HasPrefix(r.URL.Path, user.Prefix) {
|
if (r.Method == "GET" || r.Method == "HEAD") && strings.HasPrefix(r.URL.Path, user.Prefix) {
|
||||||
info, err := user.FileSystem.Stat(r.Context(), strings.TrimPrefix(r.URL.Path, user.Prefix))
|
info, err := user.FileSystem.Stat(r.Context(), strings.TrimPrefix(r.URL.Path, user.Prefix))
|
||||||
if err == nil && info.IsDir() {
|
if err == nil && info.IsDir() {
|
||||||
|
|||||||
Reference in New Issue
Block a user