S32: wire repoH.MountSettingsGeneral
- SHA
eab729403619ca99d50da107cd0ca92e6c41e03d- Parents
-
99d81cf - Tree
ed5a22b
eab7294
eab729403619ca99d50da107cd0ca92e6c41e03d99d81cf
ed5a22b| Status | File | + | - |
|---|---|---|---|
| M |
internal/web/server.go
|
6 | 0 |
internal/web/server.gomodified@@ -195,6 +195,12 @@ func Run(ctx context.Context, opts Options) error { | ||
| 195 | 195 | repoH.MountSettingsBranches(r) |
| 196 | 196 | }) |
| 197 | 197 | } |
| 198 | + deps.RepoSettingsGeneralMounter = func(r chi.Router) { | |
| 199 | + r.Group(func(r chi.Router) { | |
| 200 | + r.Use(middleware.RequireUser) | |
| 201 | + repoH.MountSettingsGeneral(r) | |
| 202 | + }) | |
| 203 | + } | |
| 198 | 204 | // Issues GETs are public (subject to policy.Can), POSTs require |
| 199 | 205 | // auth. The handler enforces auth + policy per request, so we |
| 200 | 206 | // register the whole surface in the public group; an unauth |