1
1
mirror of https://github.com/bumi/lntip synced 2026-07-20 23:57:05 +00:00

add private routing hints for invoices

This commit is contained in:
ziggie
2023-01-23 10:08:26 +01:00
parent c6dc9308c3
commit 23a134b28e
2 changed files with 5 additions and 3 deletions
+2 -1
View File
@@ -47,7 +47,7 @@ type LNDclient struct {
}
// AddInvoice generates an invoice with the given price and memo.
func (c LNDclient) AddInvoice(value int64, memo string, descriptionHash []byte) (Invoice, error) {
func (c LNDclient) AddInvoice(value int64, memo string, descriptionHash []byte, private bool) (Invoice, error) {
result := Invoice{}
stdOutLogger.Printf("Adding invoice: memo=%s value=%v", memo, value)
@@ -55,6 +55,7 @@ func (c LNDclient) AddInvoice(value int64, memo string, descriptionHash []byte)
Memo: memo,
DescriptionHash: descriptionHash,
Value: value,
Private: private,
}
res, err := c.lndClient.AddInvoice(c.ctx, &invoice)
if err != nil {