Skip to content
This repository was archived by the owner on Apr 17, 2023. It is now read-only.

Commit a13a0ce

Browse files
Merge pull request #278 from camilamacedo86/RHMAP-19117
fix(Some FH request headers are not formatted correctly): RHMAP-19117
2 parents 92e3ecd + f87e7ca commit a13a0ce

File tree

4 files changed

+8
-5
lines changed

4 files changed

+8
-5
lines changed

CHANGELOG.md

+3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
# Changelog - FeedHenry Javascript SDK
22

3+
## 3.0.6 - 2018-07-20
4+
- Fix header parameters
5+
36
## 3.0.5 - 2018-06-12
47
- Add scripts to update the licenses automatically
58
- Update automatically lock dependencies file (npm-shrinkwrap.json) and licenses

npm-shrinkwrap.json

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "fh-js-sdk",
3-
"version": "3.0.5",
3+
"version": "3.0.6",
44
"description": "feedhenry js sdk",
55
"main": "dist/feedhenry.js",
66
"types": "./fh-js-sdk.d.ts",

src/modules/fhparams.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ var buildFHParams = function(){
1414
fhparams.cuid = device.getDeviceId();
1515
fhparams.cuidMap = device.getCuidMap();
1616
fhparams.destination = device.getDestination();
17-
17+
1818
if(window.device || navigator.device){
1919
fhparams.device = window.device || navigator.device;
2020
}
@@ -45,7 +45,7 @@ var buildFHParams = function(){
4545
fhparams.init = typeof(app_props.init) === "string" ? JSON.parse(app_props.init) : app_props.init;
4646
}
4747
}
48-
48+
4949
defaultParams = fhparams;
5050
logger.debug("fhparams = ", defaultParams);
5151
return fhparams;
@@ -63,7 +63,7 @@ var getFHHeaders = function(){
6363
var params = buildFHParams();
6464
for(var name in params){
6565
if(params.hasOwnProperty(name)){
66-
headers['X-FH-' + name] = params[name];
66+
headers['X-FH-' + name] = JSON.stringify(params[name]);
6767
}
6868
}
6969
return headers;

0 commit comments

Comments
 (0)