Kaynağa Gözat

Merge branch 'feature/allow-delete-method' of Wendell/pkg into master

Paul 5 yıl önce
ebeveyn
işleme
9939579380
1 değiştirilmiş dosya ile 1 ekleme ve 1 silme
  1. 1
    1
      request/request.go

+ 1
- 1
request/request.go Dosyayı Görüntüle

55
 	}
55
 	}
56
 
56
 
57
 	switch ctx.Request.Method {
57
 	switch ctx.Request.Method {
58
-	case http.MethodGet, http.MethodHead, http.MethodOptions:
58
+	case http.MethodGet, http.MethodHead, http.MethodOptions, http.MethodDelete:
59
 		ctx.JSON(http.StatusOK, data)
59
 		ctx.JSON(http.StatusOK, data)
60
 	case http.MethodPost, http.MethodPut, http.MethodPatch:
60
 	case http.MethodPost, http.MethodPut, http.MethodPatch:
61
 		ctx.JSON(http.StatusCreated, data)
61
 		ctx.JSON(http.StatusCreated, data)