Skip to content

Commit b426606

Browse files
committed
fix(cbor): copy headers when building request
1 parent d92d79b commit b426606

File tree

2 files changed

+9
-1
lines changed

2 files changed

+9
-1
lines changed
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@smithy/core": patch
3+
---
4+
5+
copy input headers when building RPCv2 CBOR request

packages/core/src/submodules/cbor/parseCborBody.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,10 @@ export const buildHttpRpcRequest = async (
100100
port,
101101
method: "POST",
102102
path: basePath.endsWith("/") ? basePath.slice(0, -1) + path : basePath + path,
103-
headers,
103+
headers: {
104+
// intentional copy.
105+
...headers,
106+
},
104107
};
105108
if (resolvedHostname !== undefined) {
106109
contents.hostname = resolvedHostname;

0 commit comments

Comments
 (0)