From 75858a604a2c78ea56931b3db9ce539750331cab Mon Sep 17 00:00:00 2001 From: Olaoluwa Osuntokun Date: Tue, 16 May 2017 19:11:43 -0700 Subject: [PATCH] lnd: use a single instance of a FeeEstimator daemon-wide --- rpcserver.go | 2 +- server.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/rpcserver.go b/rpcserver.go index a245e878..197522cf 100644 --- a/rpcserver.go +++ b/rpcserver.go @@ -688,7 +688,7 @@ func (r *rpcServer) fetchActiveChannel(chanPoint wire.OutPoint) (*lnwallet.Light // Otherwise, we create a fully populated channel state machine which // uses the db channel as backing storage. return lnwallet.NewLightningChannel(r.server.lnwallet.Signer, nil, - lnwallet.StaticFeeEstimator{FeeRate: 250}, dbChan) + r.server.feeEstimator, dbChan) } // forceCloseChan executes a unilateral close of the target channel by diff --git a/server.go b/server.go index 24698ed9..68d3cff8 100644 --- a/server.go +++ b/server.go @@ -305,7 +305,7 @@ func newServer(listenAddrs []string, notifier chainntnfs.ChainNotifier, if chanID.IsChanPoint(channel.ChanID) { return lnwallet.NewLightningChannel( wallet.Signer, notifier, - lnwallet.StaticFeeEstimator{FeeRate: 250}, + s.feeEstimator, channel) } }