summaryrefslogtreecommitdiffstats
path: root/cmd
diff options
context:
space:
mode:
authorFlorian Kaiser <florian.kaiser@fnkr.net>2016-01-31 13:28:42 +0000
committerFlorian Kaiser <florian.kaiser@fnkr.net>2016-01-31 15:30:07 +0000
commite35791b2b2888979ba53b8a9a58e1cb132026914 (patch)
tree128e988ab9d46a56ae0448c068b23ed9a3b05d70 /cmd
parent5eafe2b17eb9a1cf1068e7a3ed7a57a2730f04b0 (diff)
downloadgitea-e35791b2b2888979ba53b8a9a58e1cb132026914.tar.gz
gitea-e35791b2b2888979ba53b8a9a58e1cb132026914.zip
Only show teams the user has access to
Diffstat (limited to 'cmd')
-rw-r--r--cmd/web.go5
1 files changed, 4 insertions, 1 deletions
diff --git a/cmd/web.go b/cmd/web.go
index cf47d5c531..3949595465 100644
--- a/cmd/web.go
+++ b/cmd/web.go
@@ -350,11 +350,14 @@ func runWeb(ctx *cli.Context) {
m.Get("/members/action/:action", org.MembersAction)
m.Get("/teams", org.Teams)
+ }, middleware.OrgAssignment(true))
+
+ m.Group("/:org", func() {
m.Get("/teams/:team", org.TeamMembers)
m.Get("/teams/:team/repositories", org.TeamRepositories)
m.Route("/teams/:team/action/:action", "GET,POST", org.TeamsAction)
m.Route("/teams/:team/action/repo/:action", "GET,POST", org.TeamsRepoAction)
- }, middleware.OrgAssignment(true))
+ }, middleware.OrgAssignment(true, false, true))
m.Group("/:org", func() {
m.Get("/teams/new", org.NewTeam)