mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2025-10-22 04:48:50 +08:00
check Accept instead of content type
fix https://github.com/chrislusf/seaweedfs/issues/429
This commit is contained in:
@@ -75,7 +75,7 @@ func (fs *FilerServer) listDirectoryHandler(w http.ResponseWriter, r *http.Reque
|
||||
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)
|
||||
|
Reference in New Issue
Block a user