configui/errors.go

38 lines
697 B
Go
Raw Normal View History

2021-11-12 09:25:44 +00:00
package configui
import (
"net/http"
"kumoly.io/lib/ksrv"
)
var ErrorOniHasNoPID = ksrv.Error{
Code: http.StatusBadRequest,
ID: "ErrorOniHasNoPID",
Message: "oni has no pid",
}
var ErrorOniNotStarted = ksrv.Error{
2021-11-12 15:09:32 +00:00
Code: http.StatusConflict,
ID: "ErrorOniNotStarted",
Tmpl: "%s hasn't start",
2021-11-12 09:25:44 +00:00
}
var ErrorOniHasStarted = ksrv.Error{
Code: http.StatusConflict,
ID: "ErrorOniHasStarted",
Message: "oni has started",
}
var ErrorOniNotFound = ksrv.Error{
2021-11-12 15:09:32 +00:00
Code: http.StatusNotFound,
ID: "ErrorOniNotFound",
Tmpl: "%s not found",
2021-11-12 09:25:44 +00:00
}
var ErrorOniNotValid = ksrv.Error{
Code: http.StatusBadRequest,
ID: "ErrorOniNotValid",
Message: "oni no name or cmd",
}