feat: update template
This commit is contained in:
@@ -84,7 +84,7 @@ func (h *ApiHandler) ListApiGroups(w http.ResponseWriter, r *http.Request) {
|
||||
func (h *ApiHandler) Create(w http.ResponseWriter, r *http.Request) {
|
||||
var req request.CreateApiRequest
|
||||
|
||||
if err := httputil.BindJson(r, &req); err != nil {
|
||||
if err := httputil.BindJson(w, r, &req); err != nil {
|
||||
httputil.Fail(w, err)
|
||||
return
|
||||
}
|
||||
@@ -106,7 +106,7 @@ func (h *ApiHandler) Update(w http.ResponseWriter, r *http.Request) {
|
||||
return
|
||||
}
|
||||
|
||||
if err = httputil.BindJson(r, &req); err != nil {
|
||||
if err = httputil.BindJson(w, r, &req); err != nil {
|
||||
httputil.Fail(w, err)
|
||||
return
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user