mirror of
https://github.com/lightninglabs/loop.git
synced 2026-08-13 12:33:03 +02:00
loopd: fix errors.Is argument order
This commit is contained in:
parent
5ec5875dd7
commit
f4e7e676d4
2 changed files with 5 additions and 5 deletions
|
|
@ -892,7 +892,7 @@ func (d *Daemon) initialize(withMacaroonService bool) error {
|
|||
defer infof("Static address manager stopped")
|
||||
|
||||
err := staticAddressManager.Run(d.mainCtx, initChan)
|
||||
if err != nil && !errors.Is(context.Canceled, err) {
|
||||
if err != nil && !errors.Is(err, context.Canceled) {
|
||||
d.internalErrChan <- err
|
||||
}
|
||||
}()
|
||||
|
|
@ -924,7 +924,7 @@ func (d *Daemon) initialize(withMacaroonService bool) error {
|
|||
defer infof("Static address deposit manager stopped")
|
||||
|
||||
err := depositManager.Run(d.mainCtx, initChan)
|
||||
if err != nil && !errors.Is(context.Canceled, err) {
|
||||
if err != nil && !errors.Is(err, context.Canceled) {
|
||||
d.internalErrChan <- err
|
||||
}
|
||||
}()
|
||||
|
|
@ -956,7 +956,7 @@ func (d *Daemon) initialize(withMacaroonService bool) error {
|
|||
defer infof("Static address withdrawal manager stopped")
|
||||
|
||||
err := withdrawalManager.Run(d.mainCtx, initChan)
|
||||
if err != nil && !errors.Is(context.Canceled, err) {
|
||||
if err != nil && !errors.Is(err, context.Canceled) {
|
||||
d.internalErrChan <- err
|
||||
}
|
||||
}()
|
||||
|
|
@ -992,7 +992,7 @@ func (d *Daemon) initialize(withMacaroonService bool) error {
|
|||
infof("Starting static address loop-in manager...")
|
||||
defer infof("Static address loop-in manager stopped")
|
||||
err := staticLoopInManager.Run(d.mainCtx, initChan)
|
||||
if err != nil && !errors.Is(context.Canceled, err) {
|
||||
if err != nil && !errors.Is(err, context.Canceled) {
|
||||
d.internalErrChan <- err
|
||||
}
|
||||
}()
|
||||
|
|
|
|||
|
|
@ -194,7 +194,7 @@ func NewBoltSwapStore(dbPath string, chainParams *chaincfg.Params) (
|
|||
bdb, err := bbolt.Open(path, 0600, &bbolt.Options{
|
||||
Timeout: DefaultLoopDBTimeout,
|
||||
})
|
||||
if err == bbolt.ErrTimeout {
|
||||
if errors.Is(err, bbolt.ErrTimeout) {
|
||||
return nil, fmt.Errorf("%w: couldn't obtain exclusive lock on "+
|
||||
"%s, timed out after %v", bbolt.ErrTimeout, path,
|
||||
DefaultLoopDBTimeout)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue