forked from kevadesu/forgejo
Add latest commit in repo viewer
This commit is contained in:
parent
664bbe4f54
commit
0f68930892
6 changed files with 57 additions and 3 deletions
|
@ -50,6 +50,13 @@ func Single(ctx *middleware.Context, params martini.Params) {
|
|||
}
|
||||
}
|
||||
|
||||
commit, err := models.GetLastestCommit(params["username"], params["reponame"])
|
||||
if err != nil {
|
||||
ctx.Handle(200, "repo.Single", err)
|
||||
return
|
||||
}
|
||||
ctx.Data["LatestCommit"] = commit
|
||||
|
||||
ctx.Data["Paths"] = Paths
|
||||
ctx.Data["Treenames"] = treenames
|
||||
ctx.Data["IsRepoToolbarSource"] = true
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue