Return HTTP status 201 for created resources (#148)
Have the controller return status 201 for created resources, and have the client check for 201 response on created resources. #143
This commit is contained in:
committed by
Soam Vasani
parent
a6869ab746
commit
e1cb5f6e09
@@ -77,6 +77,7 @@ func (api *API) FunctionApiCreate(w http.ResponseWriter, r *http.Request) {
|
||||
return
|
||||
}
|
||||
|
||||
w.WriteHeader(http.StatusCreated)
|
||||
api.respondWithSuccess(w, resp)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user