Skip to content

Commit bdf58bb

Browse files
committed
rm RepoIDs
1 parent f42e8b5 commit bdf58bb

File tree

2 files changed

+2
-6
lines changed

2 files changed

+2
-6
lines changed

models/issue.go

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1194,8 +1194,7 @@ func GetIssuesByIDs(issueIDs []int64) ([]*Issue, error) {
11941194
// IssuesOptions represents options of an issue.
11951195
type IssuesOptions struct {
11961196
db.ListOptions
1197-
RepoIDs []int64 // include all repos if empty // TODO: migrate to RepoCond
1198-
RepoID int64 // overwrites RepoCond if not 0
1197+
RepoID int64 // overwrites RepoCond if not 0
11991198
RepoCond builder.Cond
12001199
AssigneeID int64
12011200
PosterID int64
@@ -1287,9 +1286,6 @@ func (opts *IssuesOptions) setupSessionNoLimit(sess *xorm.Session) {
12871286
sess.In("issue.id", opts.IssueIDs)
12881287
}
12891288

1290-
if opts.RepoCond == nil && len(opts.RepoIDs) != 0 {
1291-
opts.RepoCond = builder.In("issue.repo_id", opts.RepoIDs)
1292-
}
12931289
if opts.RepoID != 0 {
12941290
opts.RepoCond = builder.Eq{"issue.repo_id": opts.RepoID}
12951291
}

routers/web/user/home.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -528,7 +528,7 @@ func buildIssueOverview(ctx *context.Context, unitType unit.Type) {
528528
// TODO: check if user has access to repos ?
529529
repoIDs := getRepoIDs(ctx.FormString("repos"))
530530
if len(repoIDs) > 0 {
531-
opts.RepoIDs = repoIDs
531+
opts.RepoCond = builder.In("issue.repo_id", repoIDs)
532532
}
533533

534534
// ------------------------------

0 commit comments

Comments
 (0)