|
@ -120,6 +120,9 @@ func ParseUpload(r *http.Request) ( |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
isChunkedFile, _ = strconv.ParseBool(r.FormValue("cm")) |
|
|
isChunkedFile, _ = strconv.ParseBool(r.FormValue("cm")) |
|
|
|
|
|
|
|
|
|
|
|
if !isChunkedFile { |
|
|
|
|
|
|
|
|
dotIndex := strings.LastIndex(fileName, ".") |
|
|
dotIndex := strings.LastIndex(fileName, ".") |
|
|
ext, mtype := "", "" |
|
|
ext, mtype := "", "" |
|
|
if dotIndex > 0 { |
|
|
if dotIndex > 0 { |
|
@ -132,7 +135,6 @@ func ParseUpload(r *http.Request) ( |
|
|
mtype = contentType |
|
|
mtype = contentType |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
if !isChunkedFile { |
|
|
|
|
|
if part.Header.Get("Content-Encoding") == "gzip" { |
|
|
if part.Header.Get("Content-Encoding") == "gzip" { |
|
|
isGzipped = true |
|
|
isGzipped = true |
|
|
} else if operation.IsGzippable(ext, mtype) { |
|
|
} else if operation.IsGzippable(ext, mtype) { |
|
|