Skip to content

Commit 588cd3d

Browse files
chore: backup
1 parent fc79399 commit 588cd3d

File tree

5 files changed

+12
-14
lines changed

5 files changed

+12
-14
lines changed

packages/core/build/config.js

+5-5
Original file line numberDiff line numberDiff line change
@@ -115,11 +115,11 @@ const copyConfig = base => {
115115
to: 'localstorage-sync.html',
116116
toType: 'file',
117117
},
118-
{
119-
from: path.resolve(__dirname, '../src/root_files/front-channel.html'),
120-
to: 'front-channel.html',
121-
toType: 'file',
122-
},
118+
// {
119+
// from: path.resolve(__dirname, '../src/root_files/front-channel.html'),
120+
// to: 'front-channel.html',
121+
// toType: 'file',
122+
// },
123123
{
124124
from: path.resolve(__dirname, '../src/root_files/silent-callback.html'),
125125
to: 'silent-callback.html',

packages/core/src/App/AppContent.tsx

-1
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,6 @@ const AppContent: React.FC<{ passthrough: unknown }> = observer(({ passthrough }
185185
<ErrorBoundary root_store={store}>
186186
<AppModals />
187187
</ErrorBoundary>
188-
<FrontChannelIframe />
189188
{!isOAuth2Enabled && <P2PIFrame />}
190189
<AppToastMessages />
191190
<Devtools />

packages/core/src/App/Constants/routes-config.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ import Endpoint from 'Modules/Endpoint';
1111

1212
import OSRedirect from '../Containers/OSRedirect';
1313
import CallbackPage from '../../Modules/Callback/CallbackPage.tsx';
14-
import FrontChannelPage from '../../Modules/FrontChannel';
14+
import { FrontChannelPage } from '../../Modules/FrontChannel';
1515
import SilentCallbackPage from '../../Modules/SilentCallback';
1616

1717
const CFDCompareAccounts = React.lazy(

packages/core/src/Modules/FrontChannel/FrontChannelPage.tsx

+5-6
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,13 @@
11
import React from 'react';
22
import { withRouter } from 'react-router-dom';
3-
import { useStore } from '@deriv/stores';
43

54
const FrontChannelPage = () => {
6-
const store = useStore();
7-
const { logout, is_client_store_initialized } = store.client;
8-
5+
React.useLayoutEffect(() => {
6+
localStorage.removeItem('client.accounts');
7+
}, []);
98
React.useEffect(() => {
10-
if (is_client_store_initialized) logout();
11-
}, [is_client_store_initialized]);
9+
localStorage.removeItem('client.accounts');
10+
}, []);
1211
return <></>;
1312
};
1413

packages/core/src/root_files/front-channel.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<meta charset="utf-8" />
66
<meta name="referrer" content="origin" />
77
<script>
8-
if (window.parent.location.origin !== window.location.origin) localStorage.removeItem('client.accounts');
8+
localStorage.removeItem('client.accounts');
99
</script>
1010
</head>
1111

0 commit comments

Comments
 (0)