Skip to content

Commit cc08d3f

Browse files
author
Chris Park
committed
RCB-368 added check for user_key existence
1 parent c76d6f2 commit cc08d3f

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

lib/rosetteRequest.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,9 @@ rosetteRequest.prototype.makeRequest = function(requestType, userKey, urlParts,
6969
"content-type": "application/json",
7070
"user-agent": "rosetteapinode/" + BINDING_VERSION
7171
}
72-
headers["X-RosetteAPI-Key"] = userKey;
72+
if (userKey != null) {
73+
headers["X-RosetteAPI-Key"] = userKey;
74+
}
7375

7476

7577
var options = {

0 commit comments

Comments
 (0)