Skip to content

Commit

Permalink
Upgrade golangci-lint to v1.40.1
Browse files Browse the repository at this point in the history
  • Loading branch information
Sergio Andres Virviescas Santana committed May 15, 2021
1 parent 2ce71d4 commit a3be67e
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
include:
- stage: lint
script:
- curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.39.0
- curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.40.1
- golangci-lint run

- stage: cross compilation
Expand Down
4 changes: 3 additions & 1 deletion router.go
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,9 @@ func (r *Router) getGroupFullPath(path string) string {
func (r *Router) handler(fn View, middle Middlewares) fasthttp.RequestHandler {
middle = r.buildMiddlewares(middle)

chain := append(middle.Before, func(ctx *RequestCtx) error {
chain := make([]Middleware, 0)
chain = append(chain, middle.Before...)
chain = append(chain, func(ctx *RequestCtx) error {
if !ctx.skipView {
if err := fn(ctx); err != nil {
return err
Expand Down

0 comments on commit a3be67e

Please sign in to comment.