summaryrefslogtreecommitdiffstats
path: root/routers
diff options
context:
space:
mode:
authorlstahlman <luke.stahlman@gmail.com>2016-07-11 15:28:51 -0700
committer无闻 <u@gogs.io>2016-07-12 06:28:51 +0800
commit846bf2ca9fcb4cd8cc85cc189e9f153c04080e5d (patch)
tree653ec82d5c7a588385129b2710e43a01a88b6e79 /routers
parentf4ab50501ebc3d216dd216c72f5f8ff53fa6efc1 (diff)
downloadgitea-846bf2ca9fcb4cd8cc85cc189e9f153c04080e5d.tar.gz
gitea-846bf2ca9fcb4cd8cc85cc189e9f153c04080e5d.zip
Add timestamps to repository api response (#3255)
Additional properties: created_at, updated_at
Diffstat (limited to 'routers')
-rw-r--r--routers/api/v1/convert/convert.go2
1 files changed, 2 insertions, 0 deletions
diff --git a/routers/api/v1/convert/convert.go b/routers/api/v1/convert/convert.go
index 0bd22f5762..52f28e7dd5 100644
--- a/routers/api/v1/convert/convert.go
+++ b/routers/api/v1/convert/convert.go
@@ -55,6 +55,8 @@ func ToRepository(owner *models.User, repo *models.Repository, permission api.Pe
Stars: repo.NumStars,
Forks: repo.NumForks,
Watchers: repo.NumWatches,
+ Created: repo.Created,
+ Updated: repo.Updated,
Permissions: permission,
}
}