mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2024-11-10 20:16:20 +01:00
Merge pull request #2548 from fnkr/fix-unescaped-regex
Escape unescaped periods in route regular expression
This commit is contained in:
commit
452bc385fe
1 changed files with 1 additions and 1 deletions
|
@ -516,7 +516,7 @@ func runWeb(ctx *cli.Context) {
|
||||||
m.Get("/forks", repo.Forks)
|
m.Get("/forks", repo.Forks)
|
||||||
}, middleware.RepoRef())
|
}, middleware.RepoRef())
|
||||||
|
|
||||||
m.Get("/compare/:before([a-z0-9]{40})...:after([a-z0-9]{40})", repo.CompareDiff)
|
m.Get("/compare/:before([a-z0-9]{40})\\.\\.\\.:after([a-z0-9]{40})", repo.CompareDiff)
|
||||||
}, ignSignIn, middleware.RepoAssignment(), repo.MustBeNotBare)
|
}, ignSignIn, middleware.RepoAssignment(), repo.MustBeNotBare)
|
||||||
m.Group("/:username/:reponame", func() {
|
m.Group("/:username/:reponame", func() {
|
||||||
m.Get("/stars", repo.Stars)
|
m.Get("/stars", repo.Stars)
|
||||||
|
|
Loading…
Reference in a new issue