mirror of
https://github.com/go-gitea/gitea.git
synced 2026-10-07 16:27:00 +02:00
Hide activity contributors, recent commits and code frequrency left tabs if there is no code permission (#34053)
When a team have no code unit permission of a repository, the member of the team should not view activity contributors, recent commits and code frequrency. --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
This commit is contained in:
1 parent
bf9500b3f2
commit
49899070cd
4 files changed
+15
-26
No files matched your search
@@ -34,7 +34,7 @@ func CodeFrequencyData(ctx *context.Context) {
|
||||
ctx.Status(http.StatusAccepted)
|
||||
return
|
||||
}
|
||||
ctx.ServerError("GetCodeFrequencyData", err)
|
||||
ctx.ServerError("GetContributorStats", err)
|
||||
} else {
|
||||
ctx.JSON(http.StatusOK, contributorStats["total"].Weeks)
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user