diff options
Diffstat (limited to 'middleware/pkg/dnsutil/join.go')
-rw-r--r-- | middleware/pkg/dnsutil/join.go | 19 |
1 files changed, 0 insertions, 19 deletions
diff --git a/middleware/pkg/dnsutil/join.go b/middleware/pkg/dnsutil/join.go deleted file mode 100644 index 515bf3dad..000000000 --- a/middleware/pkg/dnsutil/join.go +++ /dev/null @@ -1,19 +0,0 @@ -package dnsutil - -import ( - "strings" - - "github.com/miekg/dns" -) - -// Join joins labels to form a fully qualified domain name. If the last label is -// the root label it is ignored. Not other syntax checks are performed. -func Join(labels []string) string { - ll := len(labels) - if labels[ll-1] == "." { - s := strings.Join(labels[:ll-1], ".") - return dns.Fqdn(s) - } - s := strings.Join(labels, ".") - return dns.Fqdn(s) -} |