Merge pull request #2355 from joostjager/move-invoices

invoices: create package
This commit is contained in:
Olaoluwa Osuntokun authored and GitHub committed 2019-01-07 16:56:22 -08:00
commit 4ac54dce25
6 files changed
+107 -48

No files matched your search

+2 -1
View File
@@ -31,6 +31,7 @@ import (
"github.com/lightningnetwork/lnd/build"
"github.com/lightningnetwork/lnd/channeldb"
"github.com/lightningnetwork/lnd/htlcswitch"
"github.com/lightningnetwork/lnd/invoices"
"github.com/lightningnetwork/lnd/lncfg"
"github.com/lightningnetwork/lnd/lnrpc"
"github.com/lightningnetwork/lnd/lnwallet"
@@ -2613,7 +2614,7 @@ func extractPaymentIntent(rpcPayReq *rpcPaymentRequest) (rpcPaymentIntent, error
// same debug rHash. Otherwise, we pay to the rHash specified within
// the RPC request.
case cfg.DebugHTLC && bytes.Equal(payIntent.rHash[:], zeroHash[:]):
copy(payIntent.rHash[:], debugHash[:])
copy(payIntent.rHash[:], invoices.DebugHash[:])
default:
copy(payIntent.rHash[:], rpcPayReq.PaymentHash)