mirror of https://github.com/docker/docs.git
add missing status codes
Signed-off-by: Victor Vieux <vieux@docker.com>
This commit is contained in:
parent
0c446154d4
commit
ad8f7facf7
|
@ -223,6 +223,7 @@ func postContainersCreate(c *context, w http.ResponseWriter, r *http.Request) {
|
||||||
}
|
}
|
||||||
|
|
||||||
w.Header().Set("Content-Type", "application/json")
|
w.Header().Set("Content-Type", "application/json")
|
||||||
|
w.WriteHeader(http.StatusCreated)
|
||||||
fmt.Fprintf(w, "{%q:%q}", "Id", container.Id)
|
fmt.Fprintf(w, "{%q:%q}", "Id", container.Id)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
@ -245,7 +246,7 @@ func deleteContainer(c *context, w http.ResponseWriter, r *http.Request) {
|
||||||
httpError(w, err.Error(), http.StatusInternalServerError)
|
httpError(w, err.Error(), http.StatusInternalServerError)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
w.WriteHeader(http.StatusNoContent)
|
||||||
}
|
}
|
||||||
|
|
||||||
// GET /events
|
// GET /events
|
||||||
|
|
Loading…
Reference in New Issue