Skip to content

Commit 50c6509

Browse files
committed
Implement fmt.Stringer for HomeAZFix
This is to ensure that these are prett-printed properly for clients that log them.
1 parent eb9c641 commit 50c6509

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

nmagent/responses.go

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,17 @@ type NCVersionList struct {
4747
// HomeAZ.
4848
type HomeAZFix int
4949

50+
func (h HomeAZFix) String() string {
51+
switch h {
52+
case HomeAZFixInvalid:
53+
return "HomeAZFixInvalid"
54+
case HomeAZFixIPv6:
55+
return "HomeAZFixIPv6"
56+
default:
57+
return "Unknown HomeAZ Fix"
58+
}
59+
}
60+
5061
const (
5162
HomeAZFixInvalid HomeAZFix = iota
5263
HomeAZFixIPv6

0 commit comments

Comments
 (0)