- handleHeaderValueChange(e, header, 'name')}
+ theme={storedTheme}
+ onSave={onSave}
+ onChange={(newValue) =>
+ handleHeaderValueChange(
+ {
+ target: {
+ value: newValue
+ }
+ },
+ header,
+ 'name'
+ )
+ }
+ onRun={handleRun}
+ collection={collection}
/>
|
diff --git a/packages/bruno-cli/src/runner/interpolate-vars.js b/packages/bruno-cli/src/runner/interpolate-vars.js
index bfb0601d..ae30a7b2 100644
--- a/packages/bruno-cli/src/runner/interpolate-vars.js
+++ b/packages/bruno-cli/src/runner/interpolate-vars.js
@@ -51,7 +51,8 @@ const interpolateVars = (request, envVars = {}, collectionVariables = {}, proces
request.url = interpolate(request.url);
forOwn(request.headers, (value, key) => {
- request.headers[key] = interpolate(value);
+ delete request.headers[key];
+ request.headers[interpolate(key)] = interpolate(value);
});
if (request.headers['content-type'] === 'application/json') {
diff --git a/packages/bruno-electron/src/ipc/network/interpolate-vars.js b/packages/bruno-electron/src/ipc/network/interpolate-vars.js
index 7cdbcd25..fb022150 100644
--- a/packages/bruno-electron/src/ipc/network/interpolate-vars.js
+++ b/packages/bruno-electron/src/ipc/network/interpolate-vars.js
@@ -51,7 +51,8 @@ const interpolateVars = (request, envVars = {}, collectionVariables = {}, proces
request.url = interpolate(request.url);
forOwn(request.headers, (value, key) => {
- request.headers[key] = interpolate(value);
+ delete request.headers[key];
+ request.headers[interpolate(key)] = interpolate(value);
});
if (request.headers['content-type'] === 'application/json') {
|