From 61d7ed25365f29bc7247ef1bb855d2fc931400a5 Mon Sep 17 00:00:00 2001 From: Gibheer Date: Sat, 24 Apr 2021 21:36:11 +0200 Subject: [PATCH] change zone type name to zonename This should make it more obvious for what this type is intended. --- types/zone.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/types/zone.go b/types/zone.go index 13d0671..0eec776 100644 --- a/types/zone.go +++ b/types/zone.go @@ -7,15 +7,15 @@ import ( type ( // Zone represents the name of a zone. A zone must end with a `.`. - Zone string + ZoneName string ) -func (z *Zone) UnmarshalJSON(in []byte) error { +func (z *ZoneName) UnmarshalJSON(in []byte) error { in = bytes.Trim(in, `"`) if in[len(in)-1] != '.' { return fmt.Errorf("not a valid zone name") } - *z = Zone(in) + *z = ZoneName(in) return nil }