From 6585e66f97af69548cb2e4dbe594b99c1406372f Mon Sep 17 00:00:00 2001 From: astaxie Date: Sun, 3 Jan 2016 20:36:16 +0800 Subject: [PATCH] all the browser should support delete and put now --- router.go | 6 ------ 1 file changed, 6 deletions(-) diff --git a/router.go b/router.go index 69464ac2..dc37d1e8 100644 --- a/router.go +++ b/router.go @@ -664,12 +664,6 @@ func (p *ControllerRegister) ServeHTTP(rw http.ResponseWriter, r *http.Request) if !findrouter { httpMethod := r.Method - if httpMethod == "POST" && context.Input.Query("_method") == "PUT" { - httpMethod = "PUT" - } - if httpMethod == "POST" && context.Input.Query("_method") == "DELETE" { - httpMethod = "DELETE" - } if t, ok := p.routers[httpMethod]; ok { runObject := t.Match(urlPath, context) if r, ok := runObject.(*controllerInfo); ok {