Skip to content

Commit

Permalink
Re-write Offer::issuer_id documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
jkczyz committed Aug 1, 2024
1 parent af03c57 commit bfef96c
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion lightning/src/offers/offer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -626,7 +626,17 @@ macro_rules! offer_accessors { ($self: ident, $contents: expr) => {
$contents.supported_quantity()
}

/// The public key used by the recipient to sign invoices.
/// A possibly transient id of the offer's issuer.
/// - If [`Offer::paths`] is empty, MUST be `Some` and contain the recipient's public key for
/// sending an [`InvoiceRequest`].
/// - If [`Offer::paths`] is not empty, MAY be `Some` and contain a transient id.
/// - If `Some`, then the corresponding private key will be used by the recipient to sign
/// invoices.
///
/// See also [`Bolt12Invoice::signing_pubkey`].
///
/// [`InvoiceRequest`]: crate::offers::invoice_request::InvoiceRequest
/// [`Bolt12Invoice::signing_pubkey`]: crate::offers::invoice::Bolt12Invoice::signing_pubkey
pub fn issuer_id(&$self) -> Option<bitcoin::secp256k1::PublicKey> {
$contents.issuer_id()
}
Expand Down

0 comments on commit bfef96c

Please sign in to comment.