mirror of
https://github.com/lightninglabs/pool.git
synced 2026-08-13 12:33:04 +02:00
manager: distinguish between lnwallet and btcwallet/wallet err
Unfortunately there are two error messages that are very similar (the only difference is "doesn't" vs. "does not") and can both be returned, depending on the code path taken.
This commit is contained in:
parent
e3e384fc4f
commit
52131d8690
1 changed files with 7 additions and 0 deletions
|
|
@ -15,6 +15,7 @@ import (
|
|||
"github.com/btcsuite/btcd/wire"
|
||||
"github.com/btcsuite/btcutil"
|
||||
"github.com/btcsuite/btcutil/txsort"
|
||||
"github.com/btcsuite/btcwallet/wallet"
|
||||
"github.com/btcsuite/btcwallet/wallet/txrules"
|
||||
"github.com/btcsuite/btcwallet/wtxmgr"
|
||||
"github.com/lightninglabs/lndclient"
|
||||
|
|
@ -1249,9 +1250,15 @@ func (m *Manager) BumpAccountFee(ctx context.Context,
|
|||
err := m.cfg.Wallet.BumpFee(ctx, op, newFeeRate)
|
||||
if err != nil {
|
||||
// Output isn't known to lnd, continue to the next one.
|
||||
// Unfortunately there are two slightly different error
|
||||
// messages that can be returned, depending on what code
|
||||
// path is taken.
|
||||
if strings.Contains(err.Error(), lnwallet.ErrNotMine.Error()) {
|
||||
continue
|
||||
}
|
||||
if strings.Contains(err.Error(), wallet.ErrNotMine.Error()) {
|
||||
continue
|
||||
}
|
||||
|
||||
// A fatal error occurred, return it.
|
||||
return err
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue