mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2024-01-19 02:48:24 +00:00
if mt != "application/octet-stream"
became if !strings.HasPrefix(mt, "application/octet-stream") In our situation, mt can be 'application/octet-stream;charset=ISO-8859-1', so I think HasPrefix will be more accurate.
This commit is contained in:
parent
3188382ea7
commit
96b73e3e94
|
@ -89,7 +89,7 @@ func (vs *VolumeServer) GetOrHeadHandler(w http.ResponseWriter, r *http.Request)
|
||||||
}
|
}
|
||||||
if n.MimeSize > 0 {
|
if n.MimeSize > 0 {
|
||||||
mt := string(n.Mime)
|
mt := string(n.Mime)
|
||||||
if mt != "application/octet-stream" {
|
if !strings.HasPrefix(mt, "application/octet-stream") {
|
||||||
mtype = mt
|
mtype = mt
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue