diff options
author | Florian Kaiser <florian.kaiser@fnkr.net> | 2016-01-31 13:28:42 +0000 |
---|---|---|
committer | Florian Kaiser <florian.kaiser@fnkr.net> | 2016-01-31 15:30:07 +0000 |
commit | e35791b2b2888979ba53b8a9a58e1cb132026914 (patch) | |
tree | 128e988ab9d46a56ae0448c068b23ed9a3b05d70 /routers/org/teams.go | |
parent | 5eafe2b17eb9a1cf1068e7a3ed7a57a2730f04b0 (diff) | |
download | gitea-e35791b2b2888979ba53b8a9a58e1cb132026914.tar.gz gitea-e35791b2b2888979ba53b8a9a58e1cb132026914.zip |
Only show teams the user has access to
Diffstat (limited to 'routers/org/teams.go')
-rw-r--r-- | routers/org/teams.go | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/routers/org/teams.go b/routers/org/teams.go index b2128baab6..63618b9858 100644 --- a/routers/org/teams.go +++ b/routers/org/teams.go @@ -28,10 +28,7 @@ func Teams(ctx *middleware.Context) { ctx.Data["Title"] = org.FullName ctx.Data["PageIsOrgTeams"] = true - if err := org.GetTeams(); err != nil { - ctx.Handle(500, "GetTeams", err) - return - } + // org.Teams is already loaded by middleware for _, t := range org.Teams { if err := t.GetMembers(); err != nil { ctx.Handle(500, "GetMembers", err) |