htlcswitch: convert to use new kvdb abstraction
This commit is contained in:
7 files changed
+61
-58
No files matched your search
@@ -21,10 +21,10 @@ import (
|
||||
"github.com/btcsuite/btcd/wire"
|
||||
"github.com/btcsuite/btcutil"
|
||||
"github.com/btcsuite/fastsha256"
|
||||
"github.com/coreos/bbolt"
|
||||
"github.com/go-errors/errors"
|
||||
sphinx "github.com/lightningnetwork/lightning-onion"
|
||||
"github.com/lightningnetwork/lnd/channeldb"
|
||||
"github.com/lightningnetwork/lnd/channeldb/kvdb"
|
||||
"github.com/lightningnetwork/lnd/contractcourt"
|
||||
"github.com/lightningnetwork/lnd/htlcswitch/hop"
|
||||
"github.com/lightningnetwork/lnd/input"
|
||||
@@ -420,7 +420,7 @@ func createTestChannel(alicePrivKey, bobPrivKey []byte,
|
||||
aliceStoredChannels, err := dbAlice.FetchOpenChannels(aliceKeyPub)
|
||||
switch err {
|
||||
case nil:
|
||||
case bbolt.ErrDatabaseNotOpen:
|
||||
case kvdb.ErrDatabaseNotOpen:
|
||||
dbAlice, err = channeldb.Open(dbAlice.Path())
|
||||
if err != nil {
|
||||
return nil, errors.Errorf("unable to reopen alice "+
|
||||
@@ -464,7 +464,7 @@ func createTestChannel(alicePrivKey, bobPrivKey []byte,
|
||||
bobStoredChannels, err := dbBob.FetchOpenChannels(bobKeyPub)
|
||||
switch err {
|
||||
case nil:
|
||||
case bbolt.ErrDatabaseNotOpen:
|
||||
case kvdb.ErrDatabaseNotOpen:
|
||||
dbBob, err = channeldb.Open(dbBob.Path())
|
||||
if err != nil {
|
||||
return nil, errors.Errorf("unable to reopen bob "+
|
||||
|
||||
Reference in new issue
Block a user