1
1
mirror of https://github.com/go-gitea/gitea synced 2025-11-01 11:58:25 +00:00

chore: golang lint

This commit is contained in:
Jason Song
2022-11-26 22:12:52 +08:00
parent bfe0fc1533
commit ef4b3673dd
10 changed files with 15 additions and 16 deletions

View File

@@ -16,14 +16,14 @@ import (
type RunJobList []*RunJob
func (jobs RunJobList) GetRunIDs() []int64 {
var runIDsMap = make(map[int64]struct{})
runIDsMap := make(map[int64]struct{})
for _, j := range jobs {
if j.RunID == 0 {
continue
}
runIDsMap[j.RunID] = struct{}{}
}
var runIDs = make([]int64, 0, len(runIDsMap))
runIDs := make([]int64, 0, len(runIDsMap))
for runID := range runIDsMap {
runIDs = append(runIDs, runID)
}