mirror of
https://github.com/go-gitea/gitea.git
synced 2025-08-25 01:30:05 +00:00
more reverts
This commit is contained in:
parent
897c67b555
commit
065001c081
@ -1037,7 +1037,8 @@ func Routes() *web.Route {
|
|||||||
}, tokenRequiresScopes(auth_model.AccessTokenScopeCategoryUser), reqToken())
|
}, tokenRequiresScopes(auth_model.AccessTokenScopeCategoryUser), reqToken())
|
||||||
|
|
||||||
// Repositories (requires repo scope, org scope)
|
// Repositories (requires repo scope, org scope)
|
||||||
m.Post("/org/{org}/repos", tokenRequiresScopes(auth_model.AccessTokenScopeCategoryOrganization, auth_model.AccessTokenScopeCategoryRepository),
|
m.Post("/org/{org}/repos",
|
||||||
|
tokenRequiresScopes(auth_model.AccessTokenScopeCategoryOrganization, auth_model.AccessTokenScopeCategoryRepository),
|
||||||
reqToken(),
|
reqToken(),
|
||||||
bind(api.CreateRepoOption{}),
|
bind(api.CreateRepoOption{}),
|
||||||
repo.CreateOrgRepoDeprecated)
|
repo.CreateOrgRepoDeprecated)
|
||||||
@ -1552,6 +1553,7 @@ func Routes() *web.Route {
|
|||||||
m.Get("/registration-token", admin.GetRegistrationToken)
|
m.Get("/registration-token", admin.GetRegistrationToken)
|
||||||
})
|
})
|
||||||
}, tokenRequiresScopes(auth_model.AccessTokenScopeCategoryAdmin), reqToken(), reqSiteAdmin())
|
}, tokenRequiresScopes(auth_model.AccessTokenScopeCategoryAdmin), reqToken(), reqSiteAdmin())
|
||||||
|
|
||||||
m.Group("/projects", func() {
|
m.Group("/projects", func() {
|
||||||
m.Combo("/{id}").Get(projects.GetProject).
|
m.Combo("/{id}").Get(projects.GetProject).
|
||||||
Patch(bind(api.UpdateProjectPayload{}), projects.UpdateProject).
|
Patch(bind(api.UpdateProjectPayload{}), projects.UpdateProject).
|
||||||
|
Loading…
Reference in New Issue
Block a user