From 2127eb8a19e5052c20b8669d7253b55cdc667cbb Mon Sep 17 00:00:00 2001 From: Valentine Wallace Date: Thu, 15 Jun 2023 15:59:04 -0400 Subject: [PATCH] Document on claim events that amount_msat may be > invoice amount --- lightning/src/events/mod.rs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/lightning/src/events/mod.rs b/lightning/src/events/mod.rs index 3d8f89086..3fe17475f 100644 --- a/lightning/src/events/mod.rs +++ b/lightning/src/events/mod.rs @@ -387,7 +387,8 @@ pub enum Event { /// /// Payments received on LDK versions prior to 0.0.115 will have this field unset. onion_fields: Option, - /// The value, in thousandths of a satoshi, that this payment is claimable for. + /// The value, in thousandths of a satoshi, that this payment is claimable for. May be greater + /// than the invoice amount. /// /// May be less than the invoice amount if [`ChannelConfig::accept_underpaying_htlcs`] is set /// and the previous hop took an extra fee. @@ -446,7 +447,8 @@ pub enum Event { /// The payment hash of the claimed payment. Note that LDK will not stop you from /// registering duplicate payment hashes for inbound payments. payment_hash: PaymentHash, - /// The value, in thousandths of a satoshi, that this payment is for. + /// The value, in thousandths of a satoshi, that this payment is for. May be greater than the + /// invoice amount. amount_msat: u64, /// The purpose of the claimed payment, i.e. whether the payment was for an invoice or a /// spontaneous payment. -- 2.39.5