From 883edea2c10a1b7527e07bbada7c5eb06592b8ab Mon Sep 17 00:00:00 2001 From: thinkerou Date: Wed, 7 Nov 2018 20:02:30 +0800 Subject: [PATCH] remove go1.6 support: https://github.com/gin-gonic/gin/pull/1383/commits --- context.go | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/context.go b/context.go index d80c04ac..95797056 100644 --- a/context.go +++ b/context.go @@ -438,13 +438,7 @@ func (c *Context) PostFormMap(key string) map[string]string { func (c *Context) GetPostFormMap(key string) (map[string]string, bool) { req := c.Request req.ParseMultipartForm(c.engine.MaxMultipartMemory) - dicts, exist := c.get(req.PostForm, key) - - if !exist && req.MultipartForm != nil && req.MultipartForm.File != nil { - dicts, exist = c.get(req.MultipartForm.Value, key) - } - - return dicts, exist + return c.get(req.PostForm, key) } // get is an internal method and returns a map which satisfy conditions.