Remove unused firebase and domain parameter
This commit is contained in:
parent
e5a2e3961e
commit
1f5f8f1213
3 changed files with 6 additions and 18 deletions
|
@ -1,4 +1,3 @@
|
||||||
import { DOMAIN } from 'config';
|
|
||||||
import { connect } from 'react-redux';
|
import { connect } from 'react-redux';
|
||||||
import { doSetDaemonSetting } from 'redux/actions/settings';
|
import { doSetDaemonSetting } from 'redux/actions/settings';
|
||||||
import { doSetWelcomeVersion, doToggle3PAnalytics, doSignOut } from 'redux/actions/app';
|
import { doSetWelcomeVersion, doToggle3PAnalytics, doSignOut } from 'redux/actions/app';
|
||||||
|
@ -19,8 +18,7 @@ const perform = (dispatch) => ({
|
||||||
setShareDataInternal: (share) => dispatch(doSetDaemonSetting(DAEMON_SETTINGS.SHARE_USAGE_DATA, share)),
|
setShareDataInternal: (share) => dispatch(doSetDaemonSetting(DAEMON_SETTINGS.SHARE_USAGE_DATA, share)),
|
||||||
setShareDataThirdParty: (share) => dispatch(doToggle3PAnalytics(share)),
|
setShareDataThirdParty: (share) => dispatch(doToggle3PAnalytics(share)),
|
||||||
signOut: () => dispatch(doSignOut()),
|
signOut: () => dispatch(doSignOut()),
|
||||||
authenticateIfSharingData: () =>
|
authenticateIfSharingData: () => dispatch(doAuthenticate(appVersion, true, undefined, undefined)),
|
||||||
dispatch(doAuthenticate(appVersion, undefined, undefined, true, undefined, undefined, DOMAIN)),
|
|
||||||
});
|
});
|
||||||
|
|
||||||
export default connect(select, perform)(PrivacyAgreement);
|
export default connect(select, perform)(PrivacyAgreement);
|
||||||
|
|
|
@ -9,7 +9,6 @@ import * as MODALS from 'constants/modal_types';
|
||||||
import * as SETTINGS from 'constants/settings';
|
import * as SETTINGS from 'constants/settings';
|
||||||
import * as DAEMON_SETTINGS from 'constants/daemon_settings';
|
import * as DAEMON_SETTINGS from 'constants/daemon_settings';
|
||||||
import * as SHARED_PREFERENCES from 'constants/shared_preferences';
|
import * as SHARED_PREFERENCES from 'constants/shared_preferences';
|
||||||
import { DOMAIN } from 'config';
|
|
||||||
import Lbry from 'lbry';
|
import Lbry from 'lbry';
|
||||||
import { doFetchChannelListMine, doFetchCollectionListMine, doCheckPendingClaims } from 'redux/actions/claims';
|
import { doFetchChannelListMine, doFetchCollectionListMine, doCheckPendingClaims } from 'redux/actions/claims';
|
||||||
import { selectClaimForUri, selectClaimIsMineForUri, selectMyChannelClaims } from 'redux/selectors/claims';
|
import { selectClaimForUri, selectClaimIsMineForUri, selectMyChannelClaims } from 'redux/selectors/claims';
|
||||||
|
@ -353,8 +352,6 @@ export function doDaemonReady() {
|
||||||
dispatch(
|
dispatch(
|
||||||
doAuthenticate(
|
doAuthenticate(
|
||||||
appVersion,
|
appVersion,
|
||||||
undefined,
|
|
||||||
undefined,
|
|
||||||
shareUsageData,
|
shareUsageData,
|
||||||
(status) => {
|
(status) => {
|
||||||
const trendingAlgorithm =
|
const trendingAlgorithm =
|
||||||
|
@ -367,8 +364,7 @@ export function doDaemonReady() {
|
||||||
analytics.trendingAlgorithmEvent(trendingAlgorithm);
|
analytics.trendingAlgorithmEvent(trendingAlgorithm);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
undefined,
|
undefined
|
||||||
DOMAIN
|
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
dispatch({ type: ACTIONS.DAEMON_READY });
|
dispatch({ type: ACTIONS.DAEMON_READY });
|
||||||
|
|
|
@ -48,11 +48,8 @@ export function doFetchInviteStatus(shouldCallRewardList = true) {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
export function doInstallNew(appVersion, os = null, firebaseToken = null, callbackForUsersWhoAreSharingData, domain) {
|
export function doInstallNew(appVersion, callbackForUsersWhoAreSharingData, domain) {
|
||||||
const payload = { app_version: appVersion, domain };
|
const payload = { app_version: appVersion, domain };
|
||||||
if (firebaseToken) {
|
|
||||||
payload.firebase_token = firebaseToken;
|
|
||||||
}
|
|
||||||
|
|
||||||
Lbry.status().then((status) => {
|
Lbry.status().then((status) => {
|
||||||
payload.app_id =
|
payload.app_id =
|
||||||
|
@ -62,7 +59,7 @@ export function doInstallNew(appVersion, os = null, firebaseToken = null, callba
|
||||||
payload.node_id = status.lbry_id;
|
payload.node_id = status.lbry_id;
|
||||||
Lbry.version().then((version) => {
|
Lbry.version().then((version) => {
|
||||||
payload.daemon_version = version.lbrynet_version;
|
payload.daemon_version = version.lbrynet_version;
|
||||||
payload.operating_system = os || version.os_system;
|
payload.operating_system = version.os_system;
|
||||||
payload.platform = version.platform;
|
payload.platform = version.platform;
|
||||||
Lbryio.call('install', 'new', payload);
|
Lbryio.call('install', 'new', payload);
|
||||||
|
|
||||||
|
@ -107,12 +104,9 @@ function checkAuthBusy() {
|
||||||
// TODO: Call doInstallNew separately so we don't have to pass appVersion and os_system params?
|
// TODO: Call doInstallNew separately so we don't have to pass appVersion and os_system params?
|
||||||
export function doAuthenticate(
|
export function doAuthenticate(
|
||||||
appVersion,
|
appVersion,
|
||||||
os = null,
|
|
||||||
firebaseToken = null,
|
|
||||||
shareUsageData = true,
|
shareUsageData = true,
|
||||||
callbackForUsersWhoAreSharingData,
|
callbackForUsersWhoAreSharingData,
|
||||||
callInstall = true,
|
callInstall = true
|
||||||
domain = null
|
|
||||||
) {
|
) {
|
||||||
return (dispatch) => {
|
return (dispatch) => {
|
||||||
dispatch({
|
dispatch({
|
||||||
|
@ -134,7 +128,7 @@ export function doAuthenticate(
|
||||||
dispatch(doRewardList());
|
dispatch(doRewardList());
|
||||||
dispatch(doFetchInviteStatus(false));
|
dispatch(doFetchInviteStatus(false));
|
||||||
if (callInstall) {
|
if (callInstall) {
|
||||||
doInstallNew(appVersion, os, firebaseToken, callbackForUsersWhoAreSharingData, domain);
|
doInstallNew(appVersion, callbackForUsersWhoAreSharingData, DOMAIN);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
Loading…
Add table
Reference in a new issue