filterCodespacesByRepoOwner filters a list of codespaces by the owner of the repository.
(codespaces []*api.Codespace, repoOwner string)
| 253 | |
| 254 | // filterCodespacesByRepoOwner filters a list of codespaces by the owner of the repository. |
| 255 | func filterCodespacesByRepoOwner(codespaces []*api.Codespace, repoOwner string) []*api.Codespace { |
| 256 | filtered := make([]*api.Codespace, 0, len(codespaces)) |
| 257 | for _, c := range codespaces { |
| 258 | if strings.EqualFold(c.Repository.Owner.Login, repoOwner) { |
| 259 | filtered = append(filtered, c) |
| 260 | } |
| 261 | } |
| 262 | return filtered |
| 263 | } |
no outgoing calls
no test coverage detected