multi: rename FeePreference to FeeEstimateInfo
Results from running, ``` gofmt -d -w -r 'FeePreference -> FeeEstimateInfo' . ```
This commit is contained in:
15 files changed
+53
-49
No files matched your search
@@ -115,7 +115,7 @@ func (c *anchorResolver) Resolve() (ContractResolver, error) {
|
||||
resultChan, err := c.Sweeper.SweepInput(
|
||||
&anchorInput,
|
||||
sweep.Params{
|
||||
Fee: sweep.FeePreference{
|
||||
Fee: sweep.FeeEstimateInfo{
|
||||
FeeRate: relayFeeRate,
|
||||
},
|
||||
},
|
||||
|
||||
@@ -1359,7 +1359,7 @@ func (c *ChannelArbitrator) sweepAnchors(anchors *lnwallet.AnchorResolutions,
|
||||
_, err = c.cfg.Sweeper.SweepInput(
|
||||
&anchorInput,
|
||||
sweep.Params{
|
||||
Fee: sweep.FeePreference{
|
||||
Fee: sweep.FeeEstimateInfo{
|
||||
ConfTarget: deadline,
|
||||
},
|
||||
Force: force,
|
||||
|
||||
@@ -351,7 +351,7 @@ func (c *commitSweepResolver) Resolve() (ContractResolver, error) {
|
||||
// sweeper.
|
||||
c.log.Infof("sweeping commit output")
|
||||
|
||||
feePref := sweep.FeePreference{ConfTarget: commitOutputConfTarget}
|
||||
feePref := sweep.FeeEstimateInfo{ConfTarget: commitOutputConfTarget}
|
||||
resultChan, err := c.Sweeper.SweepInput(inp, sweep.Params{Fee: feePref})
|
||||
if err != nil {
|
||||
c.log.Errorf("unable to sweep input: %v", err)
|
||||
|
||||
@@ -141,7 +141,7 @@ func (s *mockSweeper) SweepInput(input input.Input, params sweep.Params) (
|
||||
}
|
||||
|
||||
func (s *mockSweeper) CreateSweepTx(inputs []input.Input,
|
||||
feePref sweep.FeePreference) (*wire.MsgTx, error) {
|
||||
feePref sweep.FeeEstimateInfo) (*wire.MsgTx, error) {
|
||||
|
||||
// We will wait for the test to supply the sweep tx to return.
|
||||
sweepTx := <-s.createSweepTxChan
|
||||
|
||||
@@ -263,7 +263,7 @@ func (h *htlcSuccessResolver) broadcastReSignedSuccessTx() (
|
||||
_, err := h.Sweeper.SweepInput(
|
||||
&secondLevelInput,
|
||||
sweep.Params{
|
||||
Fee: sweep.FeePreference{
|
||||
Fee: sweep.FeeEstimateInfo{
|
||||
ConfTarget: secondLevelConfTarget,
|
||||
},
|
||||
},
|
||||
@@ -375,7 +375,7 @@ func (h *htlcSuccessResolver) broadcastReSignedSuccessTx() (
|
||||
_, err = h.Sweeper.SweepInput(
|
||||
inp,
|
||||
sweep.Params{
|
||||
Fee: sweep.FeePreference{
|
||||
Fee: sweep.FeeEstimateInfo{
|
||||
ConfTarget: sweepConfTarget,
|
||||
},
|
||||
},
|
||||
@@ -436,7 +436,7 @@ func (h *htlcSuccessResolver) resolveRemoteCommitOutput() (
|
||||
var err error
|
||||
h.sweepTx, err = h.Sweeper.CreateSweepTx(
|
||||
[]input.Input{inp},
|
||||
sweep.FeePreference{
|
||||
sweep.FeeEstimateInfo{
|
||||
ConfTarget: sweepConfTarget,
|
||||
},
|
||||
)
|
||||
|
||||
@@ -486,7 +486,7 @@ func (h *htlcTimeoutResolver) sweepSecondLevelTx() error {
|
||||
_, err := h.Sweeper.SweepInput(
|
||||
inp,
|
||||
sweep.Params{
|
||||
Fee: sweep.FeePreference{
|
||||
Fee: sweep.FeeEstimateInfo{
|
||||
ConfTarget: secondLevelConfTarget,
|
||||
},
|
||||
Force: true,
|
||||
@@ -702,7 +702,7 @@ func (h *htlcTimeoutResolver) handleCommitSpend(
|
||||
_, err = h.Sweeper.SweepInput(
|
||||
inp,
|
||||
sweep.Params{
|
||||
Fee: sweep.FeePreference{
|
||||
Fee: sweep.FeeEstimateInfo{
|
||||
ConfTarget: sweepConfTarget,
|
||||
},
|
||||
},
|
||||
|
||||
@@ -54,7 +54,7 @@ type UtxoSweeper interface {
|
||||
// that spends from them. This method also makes an accurate fee
|
||||
// estimate before generating the required witnesses.
|
||||
CreateSweepTx(inputs []input.Input,
|
||||
feePref sweep.FeePreference) (*wire.MsgTx, error)
|
||||
feePref sweep.FeeEstimateInfo) (*wire.MsgTx, error)
|
||||
|
||||
// RelayFeePerKW returns the minimum fee rate required for transactions
|
||||
// to be relayed.
|
||||
|
||||
@@ -823,7 +823,7 @@ func (u *UtxoNursery) sweepMatureOutputs(classHeight uint32,
|
||||
utxnLog.Infof("Sweeping %v CSV-delayed outputs with sweep tx for "+
|
||||
"height %v", len(kgtnOutputs), classHeight)
|
||||
|
||||
feePref := sweep.FeePreference{ConfTarget: kgtnOutputConfTarget}
|
||||
feePref := sweep.FeeEstimateInfo{ConfTarget: kgtnOutputConfTarget}
|
||||
for _, output := range kgtnOutputs {
|
||||
// Create local copy to prevent pointer to loop variable to be
|
||||
// passed in with disastrous consequences.
|
||||
|
||||
Reference in new issue
Block a user