- The middleware that takes care of normalizing '//user2/////repo1' to
`/user2/repo1` would only set the normalized value to the Chi (Forgejo's
http router) `RoutePath` field, so Chi would correctly do the routing.
However not all components in Forgejo (like Forgejo's `context` module)
rely on Chi to get this updated path and some still rely on the value of
`(http.Request).URL.Path`, so always set the normalized value to the
http request.
- Adjusted unit test.
- Resolves forgejo/forgejo#6822
- The related issue was caused by
|
||
|---|---|---|
| .. | ||
| upload | ||
| access_log.go | ||
| api.go | ||
| api_org.go | ||
| api_test.go | ||
| base.go | ||
| base_test.go | ||
| captcha.go | ||
| context.go | ||
| context_cookie.go | ||
| context_model.go | ||
| context_request.go | ||
| context_response.go | ||
| context_template.go | ||
| context_test.go | ||
| csrf.go | ||
| org.go | ||
| package.go | ||
| pagination.go | ||
| permission.go | ||
| private.go | ||
| quota.go | ||
| repo.go | ||
| repository.go | ||
| response.go | ||
| user.go | ||
| utils.go | ||
| xsrf.go | ||
| xsrf_test.go | ||