summaryrefslogtreecommitdiffstats
path: root/models/issue.go
diff options
context:
space:
mode:
authorLunny Xiao <xiaolunwen@gmail.com>2021-06-10 08:08:19 +0800
committerGitHub <noreply@github.com>2021-06-10 02:08:19 +0200
commit179c727b4f4475c29a882502c8d7084aaf633900 (patch)
treea583252523acff05c10a3213b11004e146340696 /models/issue.go
parent5fef041079d8524537e24e8afc5d2b8c2579600c (diff)
downloadgitea-179c727b4f4475c29a882502c8d7084aaf633900.tar.gz
gitea-179c727b4f4475c29a882502c8d7084aaf633900.zip
Fix bug on getIssueIDsByRepoID (#16119)
* Fix bug on getIssueIDsByRepoID * Add test
Diffstat (limited to 'models/issue.go')
-rw-r--r--models/issue.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/models/issue.go b/models/issue.go
index 6912df6c28..760aaaab09 100644
--- a/models/issue.go
+++ b/models/issue.go
@@ -1086,7 +1086,7 @@ func getIssuesByIDs(e Engine, issueIDs []int64) ([]*Issue, error) {
func getIssueIDsByRepoID(e Engine, repoID int64) ([]int64, error) {
ids := make([]int64, 0, 10)
- err := e.Table("issue").Where("repo_id = ?", repoID).Find(&ids)
+ err := e.Table("issue").Cols("id").Where("repo_id = ?", repoID).Find(&ids)
return ids, err
}