We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 5b7aeff + 2822b1b commit 97c53ccCopy full SHA for 97c53cc
rpcserver.go
@@ -8142,7 +8142,13 @@ func (r *rpcServer) AddInvoice(ctx context.Context,
8142
return nil, fmt.Errorf("error validating invoice amount: %w",
8143
err)
8144
}
8145
+
8146
+ // We'll forward the invoice request to lnd, where we can only set one
8147
+ // of the two values. Since we've calculated the amount in mSat (but the
8148
+ // user might've set the satoshi value initially), we need to reset the
8149
+ // value field.
8150
iReq.ValueMsat = int64(invoiceAmtMsat)
8151
+ iReq.Value = 0
8152
8153
// If this is a hodl invoice, then we'll copy over the relevant fields,
8154
// then route this through the invoicerpc instead.
0 commit comments