feat: host support domain and multiple ips

This commit is contained in:
Skyxim
2023-03-12 10:53:38 +08:00
parent ae4d114802
commit 2f69b64d82
10 changed files with 188 additions and 49 deletions

11
common/utils/slice.go Normal file
View File

@ -0,0 +1,11 @@
package utils
func Filter[T comparable](tSlice []T, filter func(t T) bool) []T {
result := make([]T, 0)
for _, t := range tSlice {
if filter(t) {
result = append(result, t)
}
}
return result
}