File tree Expand file tree Collapse file tree 1 file changed +11
-2
lines changed Expand file tree Collapse file tree 1 file changed +11
-2
lines changed Original file line number Diff line number Diff line change 1
- import { getBlocknative } from './services'
1
+ import { getBlocknative , initializeBlocknative } from './services'
2
2
import { writable , derived , get } from 'svelte/store'
3
3
import { wait , makeCancelable , createInterval } from './utilities'
4
- import { validateWalletInterface , validateType } from './validation'
4
+ import { validateWalletInterface , validateType } from './validation'
5
5
import {
6
6
WritableStore ,
7
7
ReadableStore ,
@@ -16,6 +16,7 @@ import {
16
16
17
17
export const app : WritableStore = writable ( {
18
18
dappId : '' ,
19
+ apiUrl : '' ,
19
20
networkId : 1 ,
20
21
version : '' ,
21
22
mobileDevice : false ,
@@ -308,6 +309,14 @@ function createBalanceStore(initialState: string | null): BalanceStore {
308
309
currentBalance : get ( balance )
309
310
} )
310
311
312
+ if ( ! getBlocknative ( ) ) {
313
+ initializeBlocknative (
314
+ get ( app ) . dappId ,
315
+ get ( app ) . networkId ,
316
+ get ( app ) . apiUrl
317
+ )
318
+ }
319
+
311
320
if ( emitterAddress !== $address ) {
312
321
const blocknative = getBlocknative ( )
313
322
You can’t perform that action at this time.
0 commit comments