File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -398,7 +398,7 @@ func ginHandleTest(c *gin.Context) {
398
398
}
399
399
400
400
func initGin () {
401
- gin .SetMode ("release" )
401
+ gin .SetMode (gin . ReleaseMode )
402
402
}
403
403
404
404
func loadGin (routes []route ) http.Handler {
@@ -409,14 +409,14 @@ func loadGin(routes []route) http.Handler {
409
409
410
410
router := gin .New ()
411
411
for _ , route := range routes {
412
- router .Handle (route .method , route .path , []gin. HandlerFunc { h } )
412
+ router .Handle (route .method , route .path , h )
413
413
}
414
414
return router
415
415
}
416
416
417
417
func loadGinSingle (method , path string , handle gin.HandlerFunc ) http.Handler {
418
418
router := gin .New ()
419
- router .Handle (method , path , []gin. HandlerFunc { handle } )
419
+ router .Handle (method , path , handle )
420
420
return router
421
421
}
422
422
You can’t perform that action at this time.
0 commit comments