diff --git a/src/config.js b/src/config.js index 6f4feaa0c..f675749ae 100644 --- a/src/config.js +++ b/src/config.js @@ -163,6 +163,7 @@ export default { }, // we do the isCustomDapp check to differentiate b/w app.tor.us and dapps without isCustomLogin flag isCustomLogin: isCustomLogin === 'true' || !!sessionNamespace, + isPlugin: false, simplexApiHost: 'https://simplex-api.tor.us', moonpayApiHost: 'https://moonpay-api.tor.us', diff --git a/src/store/mutations.js b/src/store/mutations.js index 5a53ca766..eb4e71de5 100644 --- a/src/store/mutations.js +++ b/src/store/mutations.js @@ -262,6 +262,7 @@ export default { }, setIsPlugin(state, payload) { state.isPlugin = payload + config.isPlugin = payload }, } function localThemeSet(payload, state) { diff --git a/src/utils/utils.js b/src/utils/utils.js index ee4ea46cd..28594f6c2 100644 --- a/src/utils/utils.js +++ b/src/utils/utils.js @@ -1199,6 +1199,8 @@ export const parsePopupUrl = (url) => { localUrl.searchParams.append('isCustomLogin', config.isCustomLogin) if (config.isCustomLogin) { localUrl.searchParams.append('sessionNamespace', iframeOrigin.hostname) + } + if (config.isPlugin) { const sessionId = getSessionIdFromStorage() // this is for torus wallet plugin if (sessionId) {