Diff
Not logged in

Differences From Artifact [914f7abf83]:

To Artifact [ead5325be2]:


12
13
14
15
16
17
18

19
20
21
22
23
24
25
..
54
55
56
57
58
59
60






61
62
63
64
65
66
67
import {
  setNetworkConnected,
  setNetworkConnecting,
  setNetworkDisconnected
} from './actions/network_state';

import { setAppList } from './actions/app';


const store = configureStore();
const history = syncHistoryWithStore(hashHistory, store);

const registerNetworkStateListener = (cb) => {
  // set network listener
  if (window.safeAuthenticator && window.safeAuthenticator.setNetworkListener) {
................................................................................
const appListUpdateListenerCb = (err, apps) => {
  registerAppListUpdateListener(appListUpdateListenerCb);
  return store.dispatch(setAppList(apps));
};

networkStateListenerCb(null, window.safeAuthenticator.getNetworkState());
appListUpdateListenerCb(null, []);







render(
  <Provider store={store}>
    <Router history={history} routes={routes} />
  </Provider>,
  document.getElementById('safe-auth-home')
);







>







 







>
>
>
>
>
>







12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
..
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
import {
  setNetworkConnected,
  setNetworkConnecting,
  setNetworkDisconnected
} from './actions/network_state';

import { setAppList } from './actions/app';
import { setInviteCode, toggleInvitePopup } from './actions/auth';

const store = configureStore();
const history = syncHistoryWithStore(hashHistory, store);

const registerNetworkStateListener = (cb) => {
  // set network listener
  if (window.safeAuthenticator && window.safeAuthenticator.setNetworkListener) {
................................................................................
const appListUpdateListenerCb = (err, apps) => {
  registerAppListUpdateListener(appListUpdateListenerCb);
  return store.dispatch(setAppList(apps));
};

networkStateListenerCb(null, window.safeAuthenticator.getNetworkState());
appListUpdateListenerCb(null, []);

window.addEventListener('message', (evt) => {
  console.warn('Invitation code ::', evt.data);
  store.dispatch(setInviteCode(evt.data));
  store.dispatch(toggleInvitePopup());
}, false);

render(
  <Provider store={store}>
    <Router history={history} routes={routes} />
  </Provider>,
  document.getElementById('safe-auth-home')
);