File tree Expand file tree Collapse file tree 3 files changed +0
-37
lines changed
Expand file tree Collapse file tree 3 files changed +0
-37
lines changed Original file line number Diff line number Diff line change @@ -6,7 +6,6 @@ import { TWalletName } from '../store/types/wallet';
66import { EAvailableNetwork } from './networks' ;
77import {
88 getOnChainWalletAsync ,
9- // getOnChainWallet,
109 getSelectedNetwork ,
1110 getSelectedWallet ,
1211} from './wallet' ;
Original file line number Diff line number Diff line change @@ -274,22 +274,6 @@ export const getBlockHex = async ({
274274 return await electrum . getBlockHex ( { height } ) ;
275275} ;
276276
277- /**
278- * Returns the block hash given a block hex.
279- * Leaving blockHex empty will return the last known block hash from storage.
280- * @param {string } [blockHex]
281- * @param {EAvailableNetwork } [selectedNetwork]
282- * @returns {string }
283- */
284- // export const getBlockHashFromHex = ({
285- // blockHex,
286- // }: {
287- // blockHex?: string;
288- // }): string => {
289- // const electrum = getOnChainWalletElectrum();
290- // return electrum.getBlockHashFromHex({ blockHex });
291- // };
292-
293277/**
294278 * Returns last known block height, and it's corresponding hex from local storage.
295279 * @returns {IHeader }
Original file line number Diff line number Diff line change @@ -98,13 +98,6 @@ const bip32 = BIP32Factory(ecc);
9898
9999let addressGenerator : BitcoinActions | undefined ;
100100let globalWallet : TWallet ;
101- // let globalWalletPromise: Promise<TWallet> & {
102- // resolve?: (wallet: TWallet) => void;
103- // reject?: (error: Error) => void;
104- // } = new Promise((resolve, reject) => {
105- // globalWalletPromise.resolve = resolve;
106- // globalWalletPromise.reject = reject;
107- // });
108101
109102export const setupAddressGenerator = async ( {
110103 selectedWallet = getSelectedWallet ( ) ,
@@ -139,17 +132,6 @@ export const setupAddressGenerator = async ({
139132 }
140133} ;
141134
142- // export const waitForWallet = async (): Promise<void> => {
143- // if (globalWallet) {
144- // return;
145- // }
146- // return new Promise((resolve) => {
147- // setTimeout(() => {
148- // resolve(waitForWallet());
149- // }, 100);
150- // });
151- // };
152-
153135/*
154136 * Wait for wallet to be ready
155137 */
@@ -183,8 +165,6 @@ export const refreshWallet = async ({
183165 InteractionManager . runAfterInteractions ( ( ) => resolve ( null ) ) ;
184166 } ) ;
185167
186- // await waitForWallet();
187-
188168 let notificationTxid : string | undefined ;
189169
190170 if ( onchain ) {
You can’t perform that action at this time.
0 commit comments