Browse Source

check Accept instead of content type

fix https://github.com/chrislusf/seaweedfs/issues/429
pull/430/head
Chris Lu 8 years ago
parent
commit
e61c9af523
  1. 4
      weed/server/filer_server_handlers_read.go

4
weed/server/filer_server_handlers_read.go

@ -74,8 +74,8 @@ func (fs *FilerServer) listDirectoryHandler(w http.ResponseWriter, r *http.Reque
lastFileName,
shouldDisplayLoadMore,
}
if strings.ToLower(r.Header.Get("Content-Type")) == "application/json" {
if r.Header.Get("Accept") == "application/json" {
writeJsonQuiet(w, r, http.StatusOK, args)
} else {
ui.StatusTpl.Execute(w, args)

|||||||
100:0
Loading…
Cancel
Save