Fix unmarshal error.

This commit is contained in:
davidnewhall2 2019-07-07 20:27:05 -07:00
parent e565331665
commit 2499930efe
2 changed files with 2 additions and 1 deletions

View File

@ -158,6 +158,7 @@ func (u USG) Points() ([]*influx.Point, error) {
"device_mac": u.Mac,
"site_name": u.SiteName,
"name": p.Name,
"up": p.Up.Txt,
"dhcpd_dns_enabled": p.DhcpdDNSEnabled.Txt,
"dhcpd_enabled": p.DhcpdEnabled.Txt,
"dhcpd_ntp_enabled": p.DhcpdNtpEnabled.Txt,

View File

@ -185,7 +185,7 @@ type USG struct {
Mac string `json:"mac"`
IsGuest FlexBool `json:"is_guest"`
IP string `json:"ip"`
Up string `json:"up"`
Up FlexBool `json:"up"`
NumSta FlexInt `json:"num_sta"`
RxBytes FlexInt `json:"rx_bytes"`
RxPackets FlexInt `json:"rx_packets"`