cloudapi: rename composeId → jobId
It's the id from the job.
This commit is contained in:
parent
1f87958681
commit
f8c640c7ef
1 changed files with 2 additions and 3 deletions
|
|
@ -199,14 +199,13 @@ func (server *Server) Compose(w http.ResponseWriter, r *http.Request) {
|
|||
|
||||
// ComposeStatus handles a /compose/{id} GET request
|
||||
func (server *Server) ComposeStatus(w http.ResponseWriter, r *http.Request, id string) {
|
||||
composeId, err := uuid.Parse(id)
|
||||
|
||||
jobId, err := uuid.Parse(id)
|
||||
if err != nil {
|
||||
http.Error(w, fmt.Sprintf("Invalid format for parameter id: %s", err), http.StatusBadRequest)
|
||||
return
|
||||
}
|
||||
|
||||
status, err := server.workers.JobStatus(composeId)
|
||||
status, err := server.workers.JobStatus(jobId)
|
||||
if err != nil {
|
||||
http.Error(w, fmt.Sprintf("Job %s not found: %s", id, err), http.StatusNotFound)
|
||||
return
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue