Skip to content

Commit 502f23d

Browse files
authored
fix(Insight): add missing param in be73b28 (#464)
1 parent 1a79b7e commit 502f23d

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/request.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ const ajax = (method, resourceUrl, data, headers = {}, onprogress) => {
5959
});
6060
};
6161

62-
const setAppId = (headers, signKey) => {
62+
const setAppKey = (headers, signKey) => {
6363
if (signKey) {
6464
headers['X-LC-Sign'] = sign(AV.applicationKey);
6565
} else {
@@ -87,10 +87,10 @@ const setHeaders = (authOptions = {}, signKey) => {
8787
}
8888
} else {
8989
console.warn('masterKey is not set, fall back to use appKey');
90-
setAppId(headers, signKey);
90+
setAppKey(headers, signKey);
9191
}
9292
} else {
93-
setAppId(headers, signKey);
93+
setAppKey(headers, signKey);
9494
}
9595
if (AV.hookKey) {
9696
headers['X-LC-Hook-Key'] = AV.hookKey;
@@ -278,7 +278,7 @@ const AVRequest = (route, className, objectId, method, dataObject = {}, authOpti
278278
}
279279
return getServerURLPromise.then(() => {
280280
const apiURL = createApiUrl(route, className, objectId, method, dataObject);
281-
return setHeaders(authOptions).then(
281+
return setHeaders(authOptions, route !== 'bigquery').then(
282282
headers => ajax(method, apiURL, dataObject, headers)
283283
.then(
284284
null,

0 commit comments

Comments
 (0)