summaryrefslogtreecommitdiffstats
path: root/models
diff options
context:
space:
mode:
authorUnknwon <joe2010xtmf@163.com>2014-09-05 17:28:09 -0400
committerUnknwon <joe2010xtmf@163.com>2014-09-05 17:28:09 -0400
commitab7206d6b787645956b0279f729bd7b22cbed690 (patch)
tree708566eff3437c25984e7ae91f3c34f254868547 /models
parent033a7f022401fb1bd5fdc540f24ba26f5ab64a75 (diff)
downloadgitea-ab7206d6b787645956b0279f729bd7b22cbed690.tar.gz
gitea-ab7206d6b787645956b0279f729bd7b22cbed690.zip
Fix #348
Diffstat (limited to 'models')
-rw-r--r--models/repo.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/models/repo.go b/models/repo.go
index 23d44a6b80..341e7e47a1 100644
--- a/models/repo.go
+++ b/models/repo.go
@@ -972,8 +972,8 @@ func GetRepositories(uid int64, private bool) ([]*Repository, error) {
}
// GetRecentUpdatedRepositories returns the list of repositories that are recently updated.
-func GetRecentUpdatedRepositories() (repos []*Repository, err error) {
- err = x.Where("is_private=?", false).Limit(5).Desc("updated").Find(&repos)
+func GetRecentUpdatedRepositories(num int) (repos []*Repository, err error) {
+ err = x.Where("is_private=?", false).Limit(num).Desc("updated").Find(&repos)
return repos, err
}