Skip to content

Commit

Permalink
fix outlet switch action logic
Browse files Browse the repository at this point in the history
  • Loading branch information
ranjib committed Sep 25, 2022
1 parent 2585181 commit a1ce3e0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion esp32/pin.go
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ func (p *pin) Write(b bool) error {
}
action := "off"
if b {
action = "off"
action = "on"
}
baseUri := "http://%s/outlets/%d/%s"
uri := fmt.Sprintf(baseUri, p.address, p.number, action)
Expand Down

0 comments on commit a1ce3e0

Please sign in to comment.