Skip to content

Commit

Permalink
chore: minor
Browse files Browse the repository at this point in the history
  • Loading branch information
andig committed Oct 21, 2024
1 parent cfa35f2 commit 2711690
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions meter/tq-em420.go
Original file line number Diff line number Diff line change
Expand Up @@ -124,21 +124,19 @@ func NewTqEm420FromConfig(other map[string]interface{}) (api.Meter, error) {
}

req, err := request.New(http.MethodGet, fmt.Sprintf("%s/api/json/"+cc.Device+"/values/smart-meter", base), nil, headers)

if err == nil {
err = client.DoJSON(req, &res)
}

return res, err
}, cc.Cache)

m := &TqEM420{
dataG: dataG,
if _, err := dataG(); err != nil {
return nil, err
}

_, err := dataG()
if err != nil {
return nil, err
m := &TqEM420{
dataG: dataG,
}

return m, nil
Expand Down

0 comments on commit 2711690

Please sign in to comment.