mirror of
https://github.com/ClusterCockpit/cc-backend
synced 2025-03-03 21:45:55 +01:00
fix: Do not allow to start a job with a state != running
This commit is contained in:
parent
b731395689
commit
2fdac85d31
@ -772,9 +772,8 @@ func (api *RestApi) startJob(rw http.ResponseWriter, r *http.Request) {
|
||||
return
|
||||
}
|
||||
|
||||
if req.State == "" {
|
||||
req.State = schema.JobStateRunning
|
||||
}
|
||||
req.State = schema.JobStateRunning
|
||||
|
||||
if err := importer.SanityChecks(&req.BaseJob); err != nil {
|
||||
handleError(err, http.StatusBadRequest, rw)
|
||||
return
|
||||
|
Loading…
x
Reference in New Issue
Block a user