mirror of
https://github.com/adnanh/webhook.git
synced 2025-05-12 08:34:43 +00:00
fix
This commit is contained in:
parent
6c6f353c88
commit
a4ce24550c
1 changed files with 1 additions and 3 deletions
|
@ -65,14 +65,12 @@ func rootHandler() string {
|
|||
}
|
||||
|
||||
func hookHandler(req *http.Request, params martini.Params) string {
|
||||
var p map[string]interface{}
|
||||
p := make(map[string]interface{})
|
||||
|
||||
if req.Header.Get("Content-Type") == "application/json" {
|
||||
decoder := json.NewDecoder(req.Body)
|
||||
decoder.UseNumber()
|
||||
|
||||
p = make(map[string]interface{})
|
||||
|
||||
err := decoder.Decode(&p)
|
||||
|
||||
if err != nil {
|
||||
|
|
Loading…
Add table
Reference in a new issue