Use @mempool/electrum-client lib as Electrum Client lib.

This commit is contained in:
softsimon 2020-12-29 14:14:34 +07:00
parent a3644e23a7
commit ae87694bc3
No known key found for this signature in database
GPG Key ID: 488D7DCFB5A430D7

View File

@ -3,18 +3,13 @@ import { AbstractBitcoinApi } from './bitcoin-api-abstract-factory';
import { IBitcoinApi } from './bitcoin-api.interface';
import { IEsploraApi } from './esplora-api.interface';
import { IElectrumApi } from './electrum-api.interface';
import * as sha256 from 'crypto-js/sha256';
import * as hexEnc from 'crypto-js/enc-hex';
import BitcoinApi from './bitcoin-api';
import bitcoinBaseApi from './bitcoin-base.api';
import mempool from '../mempool';
import logger from '../../logger';
// @ts-ignore
global.net = require('net');
// @ts-ignore
global.tls = require('tls');
import * as ElectrumClient from 'electrum-client';
import * as ElectrumClient from '@mempool/electrum-client';
import * as sha256 from 'crypto-js/sha256';
import * as hexEnc from 'crypto-js/enc-hex';
class BitcoindElectrsApi extends BitcoinApi implements AbstractBitcoinApi {
private electrumClient: any;