Use chi style middle ware

This commit is contained in:
James Jeffrey
2017-07-19 13:44:26 -07:00
committed by Travis Reeder
parent 570e9265f1
commit cf2c3cf404
21 changed files with 192 additions and 240 deletions

View File

@@ -8,7 +8,7 @@ import (
)
func (s *Server) handleAppCreate(c *gin.Context) {
ctx := c.MustGet("mctx").(MiddlewareContext)
ctx := c.Request.Context()
var wapp models.AppWrapper
@@ -23,7 +23,7 @@ func (s *Server) handleAppCreate(c *gin.Context) {
return
}
if err := wapp.Validate(); err != nil {
if err = wapp.Validate(); err != nil {
handleErrorResponse(c, err)
return
}