@gocommerce/utils
Advanced tools
Comparing version 0.7.1 to 0.7.2
@@ -42,2 +42,3 @@ 'use strict'; | ||
var adicionalHeaders = arguments.length > 7 && arguments[7] !== undefined ? arguments[7] : {}; | ||
var adicionalProps = arguments.length > 8 && arguments[8] !== undefined ? arguments[8] : {}; | ||
@@ -58,3 +59,3 @@ var account, start_time, headers, operationId, urlWithoutHttps, isHttps, isGraphql, baseUrl, requestParams, _metricLogger; | ||
baseUrl = 'http://api.gocommerce.com/'; | ||
requestParams = { | ||
requestParams = (0, _extends3.default)({ | ||
baseURL: '' + baseUrl + account, | ||
@@ -69,3 +70,3 @@ url: urlWithoutHttps, | ||
}, operationId && (0, _defineProperty3.default)({}, 'X-OperationId', operationId[0] + '|' + (parseInt(operationId[1]) + 1)), !isGraphql && { Cookie: ctx.request.header.cookie || '' }, (0, _functions.getSubset)(['referer', 'x-forwarded-for', 'x-forwarded-host'], ctx.request.header), isHttps && { 'X-Vtex-Use-Https': true }, adicionalHeaders) | ||
}; | ||
}, adicionalProps); | ||
@@ -112,3 +113,3 @@ _metricLogger = function _metricLogger(action, adicionalInformation) { | ||
return function makeApiCall(_x2, _x3, _x4, _x5, _x6, _x7, _x8) { | ||
return function makeApiCall(_x3, _x4, _x5, _x6, _x7, _x8, _x9) { | ||
return _ref.apply(this, arguments); | ||
@@ -115,0 +116,0 @@ }; |
{ | ||
"name": "@gocommerce/utils", | ||
"version": "0.7.1", | ||
"version": "0.7.2", | ||
"description": "", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
41868
852