update variable name

This commit is contained in:
seanyesmunt 2020-03-16 18:00:46 -04:00
parent b27a99aaa3
commit a53cffb0d8
3 changed files with 20 additions and 15 deletions

10
dist/bundle.es.js vendored
View file

@ -1275,7 +1275,7 @@ function doFetchInviteStatus() {
});
};
}
function doInstallNew(appVersion, os = null, firebaseToken = null, callback) {
function doInstallNew(appVersion, os = null, firebaseToken = null, callbackForUsersWhoAreSharingData) {
const payload = {
app_version: appVersion
};
@ -1293,14 +1293,14 @@ function doInstallNew(appVersion, os = null, firebaseToken = null, callback) {
payload.platform = version.platform;
Lbryio.call('install', 'new', payload);
if (callback) {
callback(status);
if (callbackForUsersWhoAreSharingData) {
callbackForUsersWhoAreSharingData(status);
}
});
});
} // TODO: Call doInstallNew separately so we don't have to pass appVersion and os_system params?
function doAuthenticate(appVersion, os = null, firebaseToken = null, shareUsageData = true, callback) {
function doAuthenticate(appVersion, os = null, firebaseToken = null, shareUsageData = true, callbackForUsersWhoAreSharingData) {
return dispatch => {
dispatch({
type: AUTHENTICATION_STARTED
@ -1318,7 +1318,7 @@ function doAuthenticate(appVersion, os = null, firebaseToken = null, shareUsageD
if (shareUsageData) {
dispatch(doRewardList());
dispatch(doFetchInviteStatus());
doInstallNew(appVersion, os, firebaseToken, callback);
doInstallNew(appVersion, os, firebaseToken, callbackForUsersWhoAreSharingData);
}
});
}).catch(error => {

10
dist/bundle.js vendored
View file

@ -4904,7 +4904,7 @@ function doFetchInviteStatus() {
function doInstallNew(appVersion) {
var os = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
var firebaseToken = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;
var callback = arguments.length > 3 ? arguments[3] : undefined;
var callbackForUsersWhoAreSharingData = arguments.length > 3 ? arguments[3] : undefined;
var payload = {
app_version: appVersion
};
@ -4922,8 +4922,8 @@ function doInstallNew(appVersion) {
payload.platform = version.platform;
lbryio__WEBPACK_IMPORTED_MODULE_5__["default"].call('install', 'new', payload);
if (callback) {
callback(status);
if (callbackForUsersWhoAreSharingData) {
callbackForUsersWhoAreSharingData(status);
}
});
});
@ -4933,7 +4933,7 @@ function doAuthenticate(appVersion) {
var os = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
var firebaseToken = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;
var shareUsageData = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : true;
var callback = arguments.length > 4 ? arguments[4] : undefined;
var callbackForUsersWhoAreSharingData = arguments.length > 4 ? arguments[4] : undefined;
return function (dispatch) {
dispatch({
type: constants_action_types__WEBPACK_IMPORTED_MODULE_1__["AUTHENTICATION_STARTED"]
@ -4951,7 +4951,7 @@ function doAuthenticate(appVersion) {
if (shareUsageData) {
dispatch(Object(redux_actions_rewards__WEBPACK_IMPORTED_MODULE_2__["doRewardList"])());
dispatch(doFetchInviteStatus());
doInstallNew(appVersion, os, firebaseToken, callback);
doInstallNew(appVersion, os, firebaseToken, callbackForUsersWhoAreSharingData);
}
});
})["catch"](function (error) {

View file

@ -45,7 +45,12 @@ export function doFetchInviteStatus() {
};
}
export function doInstallNew(appVersion, os = null, firebaseToken = null, callback) {
export function doInstallNew(
appVersion,
os = null,
firebaseToken = null,
callbackForUsersWhoAreSharingData
) {
const payload = { app_version: appVersion };
if (firebaseToken) {
payload.firebase_token = firebaseToken;
@ -60,8 +65,8 @@ export function doInstallNew(appVersion, os = null, firebaseToken = null, callba
payload.platform = version.platform;
Lbryio.call('install', 'new', payload);
if (callback) {
callback(status);
if (callbackForUsersWhoAreSharingData) {
callbackForUsersWhoAreSharingData(status);
}
});
});
@ -73,7 +78,7 @@ export function doAuthenticate(
os = null,
firebaseToken = null,
shareUsageData = true,
callback
callbackForUsersWhoAreSharingData
) {
return dispatch => {
dispatch({
@ -91,7 +96,7 @@ export function doAuthenticate(
if (shareUsageData) {
dispatch(doRewardList());
dispatch(doFetchInviteStatus());
doInstallNew(appVersion, os, firebaseToken, callback);
doInstallNew(appVersion, os, firebaseToken, callbackForUsersWhoAreSharingData);
}
});
})