Skip to content

Commit

Permalink
Update chi/middleware to chi/v5/middleware
Browse files Browse the repository at this point in the history
Fix go-gitea#17880

Signed-off-by: Andrew Thornton <art27@cantab.net>
  • Loading branch information
zeripath committed Dec 2, 2021
1 parent fbf3208 commit 35c78c9
Show file tree
Hide file tree
Showing 42 changed files with 128 additions and 2,572 deletions.
1 change: 0 additions & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@ require (
github.com/ethantkoenig/rupture v1.0.0
github.com/gliderlabs/ssh v0.3.3
github.com/go-asn1-ber/asn1-ber v1.5.3 // indirect
github.com/go-chi/chi v1.5.4
github.com/go-chi/chi/v5 v5.0.4
github.com/go-chi/cors v1.2.0
github.com/go-enry/go-enry/v2 v2.7.1
Expand Down
2 changes: 0 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -319,8 +319,6 @@ github.com/glycerine/goconvey v0.0.0-20190410193231-58a59202ab31/go.mod h1:Ogl1T
github.com/go-asn1-ber/asn1-ber v1.5.1/go.mod h1:hEBeB/ic+5LoWskz+yKT7vGhhPYkProFKoKdwZRWMe0=
github.com/go-asn1-ber/asn1-ber v1.5.3 h1:u7utq56RUFiynqUzgVMFDymapcOtQ/MZkh3H4QYkxag=
github.com/go-asn1-ber/asn1-ber v1.5.3/go.mod h1:hEBeB/ic+5LoWskz+yKT7vGhhPYkProFKoKdwZRWMe0=
github.com/go-chi/chi v1.5.4 h1:QHdzF2szwjqVV4wmByUnTcsbIg7UGaQ0tPF2t5GcAIs=
github.com/go-chi/chi v1.5.4/go.mod h1:uaf8YgoFazUOkPBG7fxPftUylNumIev9awIWOENIuEg=
github.com/go-chi/chi/v5 v5.0.1/go.mod h1:DslCQbL2OYiznFReuXYUmQ2hGd1aDpCnlMNITLSKoi8=
github.com/go-chi/chi/v5 v5.0.4 h1:5e494iHzsYBiyXQAHHuI4tyJS9M3V84OuX3ufIIGHFo=
github.com/go-chi/chi/v5 v5.0.4/go.mod h1:DslCQbL2OYiznFReuXYUmQ2hGd1aDpCnlMNITLSKoi8=
Expand Down
2 changes: 1 addition & 1 deletion routers/common/middleware.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import (
"code.gitea.io/gitea/modules/setting"

"github.com/chi-middleware/proxy"
"github.com/go-chi/chi/middleware"
"github.com/go-chi/chi/v5/middleware"
)

// Middlewares returns common middlewares
Expand Down
2 changes: 1 addition & 1 deletion routers/web/web.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ import (

"gitea.com/go-chi/captcha"
"github.com/NYTimes/gziphandler"
"github.com/go-chi/chi/middleware"
"github.com/go-chi/chi/v5/middleware"
"github.com/go-chi/cors"
"github.com/prometheus/client_golang/prometheus"
"github.com/tstranex/u2f"
Expand Down
3 changes: 0 additions & 3 deletions vendor/github.com/go-chi/chi/.gitignore

This file was deleted.

269 changes: 0 additions & 269 deletions vendor/github.com/go-chi/chi/CHANGELOG.md

This file was deleted.

31 changes: 0 additions & 31 deletions vendor/github.com/go-chi/chi/CONTRIBUTING.md

This file was deleted.

20 changes: 0 additions & 20 deletions vendor/github.com/go-chi/chi/LICENSE

This file was deleted.

14 changes: 0 additions & 14 deletions vendor/github.com/go-chi/chi/Makefile

This file was deleted.

Loading

0 comments on commit 35c78c9

Please sign in to comment.