mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2025-05-31 20:02:09 +00:00
Code convention
This commit is contained in:
parent
e33a104448
commit
80055bde86
11 changed files with 63 additions and 90 deletions
|
@ -24,6 +24,8 @@ func Home(ctx *middleware.Context) {
|
|||
return
|
||||
}
|
||||
|
||||
ctx.Data["PageIsHome"] = true
|
||||
|
||||
// Show recent updated repositoires for new visiters.
|
||||
repos, err := models.GetRecentUpdatedRepositories()
|
||||
if err != nil {
|
||||
|
@ -38,12 +40,11 @@ func Home(ctx *middleware.Context) {
|
|||
}
|
||||
}
|
||||
ctx.Data["Repos"] = repos
|
||||
ctx.Data["PageIsHome"] = true
|
||||
ctx.HTML(200, "home")
|
||||
}
|
||||
|
||||
func NotFound(ctx *middleware.Context) {
|
||||
ctx.Data["PageIsNotFound"] = true
|
||||
ctx.Data["Title"] = "Page Not Found"
|
||||
ctx.Data["PageIsNotFound"] = true
|
||||
ctx.Handle(404, "home.NotFound", nil)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue