diff options
author | Jeremy Lin <jeremy.lin@gmail.com> | 2021-11-22 13:59:09 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-11-22 14:59:09 -0700 |
commit | c8b5a81607c9c2799f46f42154ee311884723aa4 (patch) | |
tree | 4d2b804240d8925ef0f0c7639bbf6ed95bab342a /modules/caddyhttp/fileserver/browse.go | |
parent | eead337324593ef5cd30ebce2be26da84de00787 (diff) |
fileserver: Fix handling of symlink sizes in directory listings (#4415)
Diffstat (limited to 'modules/caddyhttp/fileserver/browse.go')
-rw-r--r-- | modules/caddyhttp/fileserver/browse.go | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/modules/caddyhttp/fileserver/browse.go b/modules/caddyhttp/fileserver/browse.go index bd4de3a..d076aec 100644 --- a/modules/caddyhttp/fileserver/browse.go +++ b/modules/caddyhttp/fileserver/browse.go @@ -141,12 +141,7 @@ func (fsrv *FileServer) loadDirectoryContents(dir *os.File, root, urlPath string // user can presumably browse "up" to parent folder if path is longer than "/" canGoUp := len(urlPath) > 1 - l, err := fsrv.directoryListing(files, canGoUp, root, urlPath, repl) - if err != nil { - return browseTemplateContext{}, err - } - - return l, nil + return fsrv.directoryListing(files, canGoUp, root, urlPath, repl), nil } // browseApplyQueryParams applies query parameters to the listing. |