misc: small fix or general refactoring i did not bother commenting

This commit is contained in:
Simone Margaritelli 2024-09-21 17:38:52 +02:00
parent 2966153adf
commit 26c532316a
21 changed files with 355 additions and 75 deletions

View file

@ -1,13 +0,0 @@
package zeroconf
import "strings"
func parseSubtypes(service string) (string, []string) {
subtypes := strings.Split(service, ",")
return subtypes[0], subtypes[1:]
}
// trimDot is used to trim the dots from the start or end of a string
func trimDot(s string) string {
return strings.Trim(s, ".")
}