lnd: use a single instance of a FeeEstimator daemon-wide

This commit is contained in:
Olaoluwa Osuntokun committed 2017-05-16 19:11:49 -07:00
1 parent 8b432f8ca6
commit 75858a604a
2 files changed
+2 -2

No files matched your search

+1 -1
View File
@@ -688,7 +688,7 @@ func (r *rpcServer) fetchActiveChannel(chanPoint wire.OutPoint) (*lnwallet.Light
// Otherwise, we create a fully populated channel state machine which // Otherwise, we create a fully populated channel state machine which
// uses the db channel as backing storage. // uses the db channel as backing storage.
return lnwallet.NewLightningChannel(r.server.lnwallet.Signer, nil, 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 // forceCloseChan executes a unilateral close of the target channel by
+1 -1
View File
@@ -305,7 +305,7 @@ func newServer(listenAddrs []string, notifier chainntnfs.ChainNotifier,
if chanID.IsChanPoint(channel.ChanID) { if chanID.IsChanPoint(channel.ChanID) {
return lnwallet.NewLightningChannel( return lnwallet.NewLightningChannel(
wallet.Signer, notifier, wallet.Signer, notifier,
lnwallet.StaticFeeEstimator{FeeRate: 250}, s.feeEstimator,
channel) channel)
} }
} }