Merge pull request #2837 from alrs/fix-webhook-dropped-err [ci skip]

plugin/webhook: fix dropped error
This commit is contained in:
Brad Rydzewski 2019-09-23 17:38:51 -07:00 committed by GitHub
commit feb3a94141
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -95,6 +95,9 @@ func (s *sender) send(endpoint, secret, event string, data []byte) error {
req.Header.Add("Digest", "SHA-256="+digest(data))
req.Header.Add("Date", time.Now().UTC().Format(http.TimeFormat))
err = signer.SignRequest("hmac-key", s.Secret, req)
if err != nil {
return err
}
res, err := s.client().Do(req)
if res != nil {
res.Body.Close()