diff --git a/weed/server/filer_server_handlers_read.go b/weed/server/filer_server_handlers_read.go index 06e4b72c8..58d1928c6 100644 --- a/weed/server/filer_server_handlers_read.go +++ b/weed/server/filer_server_handlers_read.go @@ -15,6 +15,8 @@ import ( "strings" "time" + "golang.org/x/exp/slices" + "github.com/seaweedfs/seaweedfs/weed/filer" "github.com/seaweedfs/seaweedfs/weed/glog" "github.com/seaweedfs/seaweedfs/weed/images" @@ -118,7 +120,7 @@ func (fs *FilerServer) GetOrHeadHandler(w http.ResponseWriter, r *http.Request) writeJsonQuiet(w, r, http.StatusOK, entry) return } - if entry.Attr.Mime == "" { + if slices.Contains([]string{"httpd/unix-directory", ""}, entry.Attr.Mime) { fs.listDirectoryHandler(w, r) return }