We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d91dc6d commit a395c5bCopy full SHA for a395c5b
src/ParseFile.js
@@ -243,9 +243,12 @@ var DefaultController = {
243
// To directly upload a File, we use a REST-style AJAX request
244
var headers = {
245
'X-Parse-Application-ID': CoreManager.get('APPLICATION_ID'),
246
- 'X-Parse-JavaScript-Key': CoreManager.get('JAVASCRIPT_KEY'),
247
'Content-Type': source.type || (source.file? source.file.type : null)
248
};
+ var jsKey = CoreManager.get('JAVASCRIPT_KEY');
249
+ if (jsKey) {
250
+ headers['X-Parse-JavaScript-Key'] = jsKey;
251
+ }
252
var url = CoreManager.get('SERVER_URL');
253
if (url[url.length - 1] !== '/') {
254
url += '/';
0 commit comments