@@ -51,7 +51,7 @@ const SIGNATURE_TAG: &'static str = concat!("lightning", "invoice", "signature")
51
51
/// [`Refund`]: crate::offers::refund::Refund
52
52
/// [module-level documentation]: self
53
53
pub struct InvoiceBuilder < ' a > {
54
- bytes : & ' a Vec < u8 > ,
54
+ invreq_bytes : & ' a Vec < u8 > ,
55
55
invoice : InvoiceContents ,
56
56
}
57
57
@@ -76,7 +76,7 @@ impl<'a> InvoiceBuilder<'a> {
76
76
} ;
77
77
78
78
Ok ( Self {
79
- bytes : & invoice_request. bytes ,
79
+ invreq_bytes : & invoice_request. bytes ,
80
80
invoice : InvoiceContents :: ForOffer {
81
81
invoice_request : invoice_request. contents . clone ( ) ,
82
82
fields : InvoiceFields {
@@ -152,14 +152,14 @@ impl<'a> InvoiceBuilder<'a> {
152
152
}
153
153
}
154
154
155
- let InvoiceBuilder { bytes , invoice } = self ;
156
- Ok ( UnsignedInvoice { bytes , invoice } )
155
+ let InvoiceBuilder { invreq_bytes , invoice } = self ;
156
+ Ok ( UnsignedInvoice { invreq_bytes , invoice } )
157
157
}
158
158
}
159
159
160
160
/// A semantically valid [`Invoice`] that hasn't been signed.
161
161
pub struct UnsignedInvoice < ' a > {
162
- bytes : & ' a Vec < u8 > ,
162
+ invreq_bytes : & ' a Vec < u8 > ,
163
163
invoice : InvoiceContents ,
164
164
}
165
165
@@ -173,7 +173,7 @@ impl<'a> UnsignedInvoice<'a> {
173
173
// may have contained unknown TLV records, which are not stored in `InvoiceRequestContents`
174
174
// or `RefundContents`.
175
175
let ( _, _, _, invoice_tlv_stream) = self . invoice . as_tlv_stream ( ) ;
176
- let invoice_request_bytes = WithoutSignatures ( self . bytes ) ;
176
+ let invoice_request_bytes = WithoutSignatures ( self . invreq_bytes ) ;
177
177
let unsigned_tlv_stream = ( invoice_request_bytes, invoice_tlv_stream) ;
178
178
179
179
let mut bytes = Vec :: new ( ) ;
0 commit comments