(entries []T)
| 987 | } |
| 988 | |
| 989 | func removeDuplicates[T comparable](entries []T) []T { |
| 990 | hit := map[T]bool{} |
| 991 | newEntries := []T{} |
| 992 | for _, v := range entries { |
| 993 | if !hit[v] { |
| 994 | newEntries = append(newEntries, v) |
| 995 | hit[v] = true |
| 996 | } |
| 997 | } |
| 998 | return newEntries |
| 999 | } |
| 1000 | |
| 1001 | func updateDNSConfig(flags *pflag.FlagSet, config **swarm.DNSConfig) error { |
| 1002 | newConfig := &swarm.DNSConfig{} |
no outgoing calls
no test coverage detected
searching dependent graphs…