mirror of
https://github.com/adnanh/webhook.git
synced 2025-05-23 05:42:30 +00:00
refactoring
This commit is contained in:
parent
c70c21fda7
commit
7d9d3652ba
1 changed files with 2 additions and 2 deletions
|
@ -51,7 +51,7 @@ func main() {
|
||||||
}
|
}
|
||||||
|
|
||||||
func rootHandler() string {
|
func rootHandler() string {
|
||||||
return fmt.Sprintf("go-webhook %s running for %s serving %d hook(s)\n%+v", version, time.Since(appStart).String(), webhooks.Count(), webhooks)
|
return fmt.Sprintf("go-webhook %s running for %s serving %d hook(s)\n", version, time.Since(appStart).String(), webhooks.Count())
|
||||||
}
|
}
|
||||||
|
|
||||||
func hookHandler(req *http.Request, params martini.Params) string {
|
func hookHandler(req *http.Request, params martini.Params) string {
|
||||||
|
@ -63,7 +63,7 @@ func hookHandler(req *http.Request, params martini.Params) string {
|
||||||
err := decoder.Decode(&p)
|
err := decoder.Decode(&p)
|
||||||
|
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return "Error occurred while parsing the payload :-("
|
// log "Error occurred while parsing the payload :-("
|
||||||
}
|
}
|
||||||
|
|
||||||
go func(id string, params interface{}) {
|
go func(id string, params interface{}) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue