Description
When creating a BOLT11 invoice with a custom PaymentHash (instead of letting LDK generate one), the Event::PaymentClaimed event does not contain a PaymentPreimage inside the PaymentPurpose.
After calling ChannelManager::claim_funds() (where the preimage is provided by the application), LDK should then be aware of the preimage.
Expected Behavior
After calling claim_funds(preimage), the subsequent Event::PaymentClaimed should include PaymentPurpose::Bolt11InvoicePayment { payment_preimage: Some(preimage), .. } even when the invoice uses a custom PaymentHash.
Actual Behavior
payment_preimage is always None for Bolt11 payments with custom PaymentHash, even after the preimage has been supplied to LDK via claim_funds().
Description
When creating a BOLT11 invoice with a custom
PaymentHash(instead of letting LDK generate one), theEvent::PaymentClaimedevent does not contain aPaymentPreimageinside thePaymentPurpose.After calling
ChannelManager::claim_funds()(where the preimage is provided by the application), LDK should then be aware of the preimage.Expected Behavior
After calling
claim_funds(preimage), the subsequentEvent::PaymentClaimedshould includePaymentPurpose::Bolt11InvoicePayment { payment_preimage: Some(preimage), .. }even when the invoice uses a customPaymentHash.Actual Behavior
payment_preimageis alwaysNonefor Bolt11 payments with customPaymentHash, even after the preimage has been supplied to LDK viaclaim_funds().