wings/server/power.go
2020-04-05 18:00:33 -07:00

13 lines
225 B
Go

package server
type PowerAction struct {
Action string `json:"action"`
}
func (pr *PowerAction) IsValid() bool {
return pr.Action == "start" ||
pr.Action == "stop" ||
pr.Action == "kill" ||
pr.Action == "restart"
}