Update upload.go
This commit is contained in:
parent
d6ebc29483
commit
654a1f0a84
|
@ -60,8 +60,7 @@ func uploadPostHandler(c web.C, w http.ResponseWriter, r *http.Request) {
|
||||||
upReq := UploadRequest{}
|
upReq := UploadRequest{}
|
||||||
uploadHeaderProcess(r, &upReq)
|
uploadHeaderProcess(r, &upReq)
|
||||||
|
|
||||||
contentType := r.Header.Get("Content-Type")
|
contentType := r.Header.Get("X-Forwarded-For")
|
||||||
srcIp := r.Header.get("X-Forwarded-For")
|
|
||||||
if strings.HasPrefix(contentType, "multipart/form-data") {
|
if strings.HasPrefix(contentType, "multipart/form-data") {
|
||||||
file, headers, err := r.FormFile("file")
|
file, headers, err := r.FormFile("file")
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|
Loading…
Reference in New Issue