Skip to content

Commit 787cbd5

Browse files
Merge pull request #8 from hookdeck/fix/add-content-length
Fix: add content length
2 parents 5e2e66a + e7ff3db commit 787cbd5

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,5 @@ coverage.txt
77
/hookdeck-linux
88
/hookdeck-windows.exe
99
default_cassette.yaml
10+
.vscode/
11+
__debug_bin

pkg/proxy/proxy.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -225,8 +225,10 @@ func (p *Proxy) processAttempt(msg websocket.IncomingMessage) {
225225
}
226226

227227
req.Body = ioutil.NopCloser(strings.NewReader(webhookEvent.Body.Request.DataString))
228+
req.ContentLength = int64(len(webhookEvent.Body.Request.DataString))
228229

229230
res, err := client.Do(req)
231+
230232
if err != nil {
231233
color := ansi.Color(os.Stdout)
232234
localTime := time.Now().Format(timeLayout)

0 commit comments

Comments
 (0)