(input string)
| 112 | } |
| 113 | |
| 114 | func parseCommaSeparatedInt64IDs(input string) []int64 { |
| 115 | parts := strings.Split(input, ",") |
| 116 | ids := make([]int64, 0, len(parts)) |
| 117 | seen := make(map[int64]struct{}, len(parts)) |
| 118 | for _, part := range parts { |
| 119 | part = strings.TrimSpace(part) |
| 120 | if part == "" { |
| 121 | continue |
| 122 | } |
| 123 | id, err := strconv.ParseInt(part, 10, 64) |
| 124 | if err != nil || id <= 0 { |
| 125 | continue |
| 126 | } |
| 127 | if _, ok := seen[id]; ok { |
| 128 | continue |
| 129 | } |
| 130 | seen[id] = struct{}{} |
| 131 | ids = append(ids, id) |
| 132 | } |
| 133 | return ids |
| 134 | } |
| 135 | |
| 136 | func buildSkillGitHubURL(skillInfo *model.SkillLibrary) string { |
| 137 | if skillInfo == nil || skillInfo.SourceType != model.SkillSourceTypeGithub { |
no outgoing calls
no test coverage detected