X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=blobdiff_plain;f=lightning%2Fsrc%2Foffers%2Frefund.rs;h=d5d80198ef29c8045f9097ddec5645fa1c47ffd7;hb=bd962fc2eb00f77da41c3c5de24d5a5337a2150d;hp=1aa36167b94a14a81af7134da8e7a4630f8d5e97;hpb=efed905a4f90a3ca86b08cd6fb111e7c790ce20d;p=rust-lightning diff --git a/lightning/src/offers/refund.rs b/lightning/src/offers/refund.rs index 1aa36167..d5d80198 100644 --- a/lightning/src/offers/refund.rs +++ b/lightning/src/offers/refund.rs @@ -310,7 +310,7 @@ impl Refund { /// A complete description of the purpose of the refund. Intended to be displayed to the user /// but with the caveat that it has not been verified in any way. pub fn description(&self) -> PrintableString { - PrintableString(&self.contents.description) + self.contents.description() } /// Duration since the Unix epoch when an invoice should no longer be sent. @@ -489,6 +489,10 @@ impl AsRef<[u8]> for Refund { } impl RefundContents { + pub fn description(&self) -> PrintableString { + PrintableString(&self.description) + } + #[cfg(feature = "std")] pub(super) fn is_expired(&self) -> bool { match self.absolute_expiry {