detect mime type before replicating to other volume servers

This commit is contained in:
Chris Lu
2020-06-19 22:11:36 -07:00
parent 044841c885
commit 16fe132a20
3 changed files with 28 additions and 10 deletions

View File

@@ -93,6 +93,7 @@ func doUploadData(uploadUrl string, filename string, cipher bool, data []byte, i
if !isInputGzipped {
if mtype == "" {
mtype = http.DetectContentType(data)
// println("detect1 mimetype to", mtype)
if mtype == "application/octet-stream" {
mtype = ""
}