Skip to content

Commit

Permalink
Merge pull request #42 from trustpilot/use-authenticated-client-to-ma…
Browse files Browse the repository at this point in the history
…ke-public-calls

Use authenticated client to make public calls
  • Loading branch information
Rick Marker authored Jun 15, 2017
2 parents d3ac6cb + c4baac0 commit ad457bd
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "trustpilot",
"version": "2.1.0",
"version": "2.2.0",
"description": "HTTP client for Trustpilot",
"homepage": "https://github.com/trustpilot/node-trustpilot",
"repository": "https://github.com/trustpilot/node-trustpilot.git",
Expand Down
5 changes: 3 additions & 2 deletions src/requestHelper.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@ class RequestHelper {
.then((responseToken) => {
return {
headers: {
authorization: `Bearer ${responseToken}`
authorization: `Bearer ${responseToken}`,
apikey: accessProvider.apiKey
}
};
});
Expand All @@ -29,7 +30,7 @@ class RequestHelper {

this.apiRequest = basicRequest.defaults({
headers: {
apiKey: accessProvider.apiKey
apikey: accessProvider.apiKey
}
});
}
Expand Down

0 comments on commit ad457bd

Please sign in to comment.