diff --git a/go.mod b/go.mod index 6b1a91a..0b32cb5 100644 --- a/go.mod +++ b/go.mod @@ -41,6 +41,7 @@ require ( go.uber.org/goleak v1.2.1 go.uber.org/zap v1.24.0 golang.org/x/crypto v0.8.0 + golang.org/x/net v0.9.0 golang.org/x/oauth2 v0.6.0 golang.org/x/sync v0.1.0 golang.org/x/sys v0.7.0 @@ -123,7 +124,6 @@ require ( golang.org/x/arch v0.3.0 // indirect golang.org/x/exp v0.0.0-20220303212507-bbda1eaf7a17 // indirect golang.org/x/image v0.6.0 // indirect - golang.org/x/net v0.9.0 // indirect golang.org/x/text v0.9.0 // indirect golang.org/x/time v0.3.0 // indirect google.golang.org/appengine v1.6.7 // indirect diff --git a/service/system.go b/service/system.go index 0d98259..5b0dace 100644 --- a/service/system.go +++ b/service/system.go @@ -113,7 +113,7 @@ func (c *systemService) GetDeviceInfo() model.DeviceInfo { osRelease, _ := file.ReadOSRelease() m.DeviceModel = osRelease["MODEL"] m.DeviceSN = osRelease["SN"] - res := httper.Get("http://127.0.0.1:"+strconv.Itoa(m.Port)+"/v1/users/status", nil) + res := httper.Get("http://127.0.0.1:"+strconv.Itoa(m.Port)+"/v1/users/status", nil) init := gjson.Get(res, "data.initialized") m.Initialized, _ = strconv.ParseBool(init.Raw)