Skip to content

Commit d2c22d5

Browse files
committed
Include payment hash in Bolt12Invoice reply path
Instead of using OffersContext::Unknown for the Bolt12Invoice reply path use OffersContext::InboundPayment to include the payment hash. OffersContext::Unknown will be removed in another commit.
1 parent a5382dd commit d2c22d5

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

lightning/src/ln/channelmanager.rs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9117,7 +9117,11 @@ where
91179117
)?;
91189118
let builder: InvoiceBuilder<DerivedSigningPubkey> = builder.into();
91199119
let invoice = builder.allow_mpp().build_and_sign(secp_ctx)?;
9120-
let reply_paths = self.create_blinded_paths(OffersContext::Unknown {})
9120+
9121+
let context = OffersContext::InboundPayment {
9122+
payment_hash: invoice.payment_hash(),
9123+
};
9124+
let reply_paths = self.create_blinded_paths(context)
91219125
.map_err(|_| Bolt12SemanticError::MissingPaths)?;
91229126

91239127
let mut pending_offers_messages = self.pending_offers_messages.lock().unwrap();

0 commit comments

Comments
 (0)