summaryrefslogtreecommitdiffstats
path: root/routers/repo/wiki.go
diff options
context:
space:
mode:
authorLunny Xiao <xiaolunwen@gmail.com>2019-08-15 22:46:21 +0800
committerGitHub <noreply@github.com>2019-08-15 22:46:21 +0800
commit85202d4784758573f80f93dbbda97a444e7ece99 (patch)
tree7957506de8657463e79f121e1b79567ef1cc84a1 /routers/repo/wiki.go
parent5a44be627c055d3e9eb406ec4a91579de78b6910 (diff)
downloadgitea-85202d4784758573f80f93dbbda97a444e7ece99.tar.gz
gitea-85202d4784758573f80f93dbbda97a444e7ece99.zip
Display ui time with customize time location (#7792)
* display ui time with customize time location * fix lint * rename UILocation to DefaultUILocation * move time related functions to modules/timeutil * fix tests * fix tests * fix build * fix swagger
Diffstat (limited to 'routers/repo/wiki.go')
-rw-r--r--routers/repo/wiki.go5
1 files changed, 3 insertions, 2 deletions
diff --git a/routers/repo/wiki.go b/routers/repo/wiki.go
index 0d965f2183..54cb4b83dd 100644
--- a/routers/repo/wiki.go
+++ b/routers/repo/wiki.go
@@ -19,6 +19,7 @@ import (
"code.gitea.io/gitea/modules/log"
"code.gitea.io/gitea/modules/markup"
"code.gitea.io/gitea/modules/markup/markdown"
+ "code.gitea.io/gitea/modules/timeutil"
"code.gitea.io/gitea/modules/util"
)
@@ -58,7 +59,7 @@ func MustEnableWiki(ctx *context.Context) {
type PageMeta struct {
Name string
SubURL string
- UpdatedUnix util.TimeStamp
+ UpdatedUnix timeutil.TimeStamp
}
// findEntryForFile finds the tree entry for a target filepath.
@@ -413,7 +414,7 @@ func WikiPages(ctx *context.Context) {
pages = append(pages, PageMeta{
Name: wikiName,
SubURL: models.WikiNameToSubURL(wikiName),
- UpdatedUnix: util.TimeStamp(c.Author.When.Unix()),
+ UpdatedUnix: timeutil.TimeStamp(c.Author.When.Unix()),
})
}
ctx.Data["Pages"] = pages