Skip to content

Commit 3c92de8

Browse files
correctly format the FQDN of the zone
No . is needed between an empty name and the zone.
1 parent 1d1ebf5 commit 3c92de8

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

types.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -327,5 +327,8 @@ func split255(s string) []string {
327327
}
328328

329329
func (rec *Record) fqdn() string {
330+
if rec.Name == "" {
331+
return rec.Zone
332+
}
330333
return rec.Name + "." + rec.Zone
331334
}

0 commit comments

Comments
 (0)