Skip to content

Commit

Permalink
fix: include headers on interactions requests
Browse files Browse the repository at this point in the history
  • Loading branch information
kikoruiz committed Jul 11, 2022
1 parent 84b5cdd commit c5a0cea
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/convertMswMatchToPact.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ export const convertMswMatchToPact = ({
method: match.request.method,
path: match.request.url.pathname,
headers: headers?.excludeHeaders
? omit(match.request.headers['_headers'], headers.excludeHeaders)
: match.request.headers['_headers'],
? omit(Object.fromEntries(match.request.headers.entries()), headers.excludeHeaders)
: Object.fromEntries(match.request.headers.entries()),
body: match.request.body || undefined,
query: match.request.url.search ? match.request.url.search.split('?')[1] : undefined
},
Expand Down

0 comments on commit c5a0cea

Please sign in to comment.