mirror of
https://github.com/adnanh/webhook.git
synced 2025-05-12 08:34:43 +00:00
github hookshot user agent fix
This commit is contained in:
parent
57db4f3ca6
commit
73278ff99b
1 changed files with 1 additions and 1 deletions
|
@ -122,7 +122,7 @@ func hookHandler(req *http.Request, params martini.Params) string {
|
|||
|
||||
payloadSignature := ""
|
||||
|
||||
if strings.Contains(req.Header.Get("User-Agent"), "Github") {
|
||||
if strings.Contains(req.Header.Get("User-Agent"), "GitHub-Hookshot") {
|
||||
if len(req.Header.Get("X-Hub-Signature")) > 5 {
|
||||
payloadSignature = req.Header.Get("X-Hub-Signature")[5:]
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue