mirror of
https://github.com/BlueWallet/BlueWallet.git
synced 2025-02-22 06:52:41 +01:00
FIX: electrum connection
This commit is contained in:
parent
b9cf5c6172
commit
c4b7c9d7a1
1 changed files with 2 additions and 3 deletions
|
@ -43,12 +43,11 @@ async function connectMain() {
|
|||
};
|
||||
await mainClient.connect();
|
||||
const ver = await mainClient.server_version('2.7.11', '1.4');
|
||||
let peers = await mainClient.serverPeers_subscribe();
|
||||
if (peers && peers.length > 0) {
|
||||
if (ver && ver[0]) {
|
||||
console.log('connected to ', ver);
|
||||
mainConnected = true;
|
||||
wasConnectedAtLeastOnce = true;
|
||||
AsyncStorage.setItem(storageKey, JSON.stringify(peers));
|
||||
// AsyncStorage.setItem(storageKey, JSON.stringify(peers)); TODO: refactor
|
||||
}
|
||||
} catch (e) {
|
||||
mainConnected = false;
|
||||
|
|
Loading…
Add table
Reference in a new issue