Compare commits

...

2 Commits

Author SHA1 Message Date
Patrick Hofmann 327655f2fc
Merge 1abf36686c into bde0a086ab 2025-07-09 16:27:32 +00:00
Patrick Hofmann 1abf36686c
fixing lint issue 2025-07-09 18:27:19 +02:00
1 changed files with 3 additions and 2 deletions

View File

@ -234,9 +234,10 @@ func setDCRestoreState(state int) error {
return err return err
} }
command := "RESTORE_MODE_OFF\n" command := "RESTORE_MODE_OFF\n"
if state == 1 { switch state {
case 1:
command = "RESTORE_MODE_ON\n" command = "RESTORE_MODE_ON\n"
} else if state == 2 { case 2:
command = "RESTORE_MODE_LAST_STATE\n" command = "RESTORE_MODE_LAST_STATE\n"
} }
_, err = port.Write([]byte(command)) _, err = port.Write([]byte(command))