diff options
Diffstat (limited to 'routers')
-rw-r--r-- | routers/web/org/projects.go | 8 | ||||
-rw-r--r-- | routers/web/repo/projects.go | 8 | ||||
-rw-r--r-- | routers/web/user/home.go | 8 |
3 files changed, 12 insertions, 12 deletions
diff --git a/routers/web/org/projects.go b/routers/web/org/projects.go index 03798a712c..f65cc6e679 100644 --- a/routers/web/org/projects.go +++ b/routers/web/org/projects.go @@ -377,16 +377,16 @@ func ViewProject(ctx *context.Context) { linkedPrsMap := make(map[int64][]*issues_model.Issue) for _, issuesList := range issuesMap { for _, issue := range issuesList { - var referencedIds []int64 + var referencedIDs []int64 for _, comment := range issue.Comments { if comment.RefIssueID != 0 && comment.RefIsPull { - referencedIds = append(referencedIds, comment.RefIssueID) + referencedIDs = append(referencedIDs, comment.RefIssueID) } } - if len(referencedIds) > 0 { + if len(referencedIDs) > 0 { if linkedPrs, err := issues_model.Issues(ctx, &issues_model.IssuesOptions{ - IssueIDs: referencedIds, + IssueIDs: referencedIDs, IsPull: util.OptionalBoolTrue, }); err == nil { linkedPrsMap[issue.ID] = linkedPrs diff --git a/routers/web/repo/projects.go b/routers/web/repo/projects.go index 4908bb796d..001f0752c3 100644 --- a/routers/web/repo/projects.go +++ b/routers/web/repo/projects.go @@ -339,16 +339,16 @@ func ViewProject(ctx *context.Context) { linkedPrsMap := make(map[int64][]*issues_model.Issue) for _, issuesList := range issuesMap { for _, issue := range issuesList { - var referencedIds []int64 + var referencedIDs []int64 for _, comment := range issue.Comments { if comment.RefIssueID != 0 && comment.RefIsPull { - referencedIds = append(referencedIds, comment.RefIssueID) + referencedIDs = append(referencedIDs, comment.RefIssueID) } } - if len(referencedIds) > 0 { + if len(referencedIDs) > 0 { if linkedPrs, err := issues_model.Issues(ctx, &issues_model.IssuesOptions{ - IssueIDs: referencedIds, + IssueIDs: referencedIDs, IsPull: util.OptionalBoolTrue, }); err == nil { linkedPrsMap[issue.ID] = linkedPrs diff --git a/routers/web/user/home.go b/routers/web/user/home.go index 44920817c9..83fc4d7162 100644 --- a/routers/web/user/home.go +++ b/routers/web/user/home.go @@ -296,17 +296,17 @@ func Milestones(ctx *context.Context) { } } - showRepoIds := make(container.Set[int64], len(showRepos)) + showRepoIDs := make(container.Set[int64], len(showRepos)) for _, repo := range showRepos { if repo.ID > 0 { - showRepoIds.Add(repo.ID) + showRepoIDs.Add(repo.ID) } } if len(repoIDs) == 0 { - repoIDs = showRepoIds.Values() + repoIDs = showRepoIDs.Values() } repoIDs = slices.DeleteFunc(repoIDs, func(v int64) bool { - return !showRepoIds.Contains(v) + return !showRepoIDs.Contains(v) }) var pagerCount int |