Skip to content

Commit

Permalink
fix: invalid hydration of Response.Request.Body (#101)
Browse files Browse the repository at this point in the history
  • Loading branch information
seborama authored Aug 26, 2022
1 parent 93dbefd commit 29a704f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cassette/track/track.go
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ func (trk *Track) ToErr() error {
// govcr only saves enough info of the http.Request to permit matching.
// Not all fields of http.Request are populated.
func (trk *Track) toHTTPRequest() *http.Request {
bodyReadCloser := io.NopCloser(bytes.NewReader(trk.Response.Body))
bodyReadCloser := io.NopCloser(bytes.NewReader(trk.Request.Body))

httpRequest := http.Request{
Method: trk.Request.Method,
Expand Down

0 comments on commit 29a704f

Please sign in to comment.