mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2024-01-19 02:48:24 +00:00
fix when no files in filer
This commit is contained in:
parent
4af6b4eb0e
commit
41aba0c02c
|
@ -23,6 +23,10 @@ func (fs *FilerServer) GetOrHeadHandler(w http.ResponseWriter, r *http.Request,
|
|||
|
||||
entry, err := fs.filer.FindEntry(filer2.FullPath(path))
|
||||
if err != nil {
|
||||
if path == "/" {
|
||||
fs.listDirectoryHandler(w, r)
|
||||
return
|
||||
}
|
||||
glog.V(1).Infof("Not found %s: %v", path, err)
|
||||
w.WriteHeader(http.StatusNotFound)
|
||||
return
|
||||
|
|
Loading…
Reference in a new issue