1
0
mirror of https://github.com/kataras/iris.git synced 2025-12-18 02:17:05 +00:00

Implement method override wrapper as requested at: #1325

Former-commit-id: e476998d8d6b10dc641b3393577937269adb694c
This commit is contained in:
Gerasimos (Makis) Maropoulos
2019-08-06 15:39:42 +03:00
parent 3fdaa897ea
commit 95ce71be9f
6 changed files with 337 additions and 15 deletions

View File

@@ -81,6 +81,8 @@ func (router *Router) BuildRouter(cPool *context.Pool, requestHandler RequestHan
// the important
router.mainHandler = func(w http.ResponseWriter, r *http.Request) {
ctx := cPool.Acquire(w, r)
// Note: we can't get all r.Context().Value key-value pairs
// and save them to ctx.values.
router.requestHandler.HandleRequest(ctx)
cPool.Release(ctx)
}