Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix typo in error message #1306

Open
ZZiigguurraatt opened this issue Jan 16, 2025 · 1 comment
Open

fix typo in error message #1306

ZZiigguurraatt opened this issue Jan 16, 2025 · 1 comment

Comments

@ZZiigguurraatt
Copy link

At

return nil, fmt.Errorf("cannot create invoice over %d asset "+

"over" should be replaced with "of".

@ZZiigguurraatt
Copy link
Author

More of the same error here:

// Given a wallet end user A, an edge node B, an asset rate of 100 milli-
// satoshi per asset unit and a flat 0.1% routing fee (to simplify the
// scenario), the following invoice based receive events can occur:
// 1. Success case: User A creates an invoice over 5,000 units (500,000 milli-
// satoshis) that is paid by the network. An HTLC over 500,500 milli-
// satoshis arrives at B. B converts the HTLC to 5,000 units and sends
// 354,000 milli-satoshis to A.
// A receives a total "worth" of 854,000 milli-satoshis, which is already
// more than the invoice amount. But at least the forwarding rule in `lnd`
// for B is not violated (outgoing amount mSat < incoming amount mSat).
// 2. Failure case: User A creates an invoice over 3,530 units (353,000 milli-
// satoshis) that is paid by the network. An HTLC over 353,530 milli-
// satoshis arrives at B. B converts the HTLC to 3,530 units and sends
// 354,000 milli-satoshis to A.
// This fails in the `lnd` forwarding logic, because the outgoing amount
// (354,000 milli-satoshis) is greater than the incoming amount (353,530
// milli-satoshis).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: 🆕 New
Development

No branches or pull requests

1 participant