@@ -783,7 +783,7 @@ pub enum Event {
783783 /// The outgoing channel between the next node and us. This is only `None` for events
784784 /// generated or serialized by versions prior to 0.0.107.
785785 next_channel_id : Option < ChannelId > ,
786- /// The fee, in milli-satoshis, which was earned as a result of the payment.
786+ /// The total fee, in milli-satoshis, which was earned as a result of the payment.
787787 ///
788788 /// Note that if we force-closed the channel over which we forwarded an HTLC while the HTLC
789789 /// was pending, the amount the next hop claimed will have been rounded down to the nearest
@@ -794,15 +794,15 @@ pub enum Event {
794794 /// If the channel which sent us the payment has been force-closed, we will claim the funds
795795 /// via an on-chain transaction. In that case we do not yet know the on-chain transaction
796796 /// fees which we will spend and will instead set this to `None`. It is possible duplicate
797- /// `PaymentForwarded` events are generated for the same payment iff `fee_earned_msat ` is
797+ /// `PaymentForwarded` events are generated for the same payment iff `total_fee_earned_msat ` is
798798 /// `None`.
799- fee_earned_msat : Option < u64 > ,
799+ total_fee_earned_msat : Option < u64 > ,
800800 /// If this is `true`, the forwarded HTLC was claimed by our counterparty via an on-chain
801801 /// transaction.
802802 claim_from_onchain_tx : bool ,
803803 /// The final amount forwarded, in milli-satoshis, after the fee is deducted.
804804 ///
805- /// The caveat described above the `fee_earned_msat ` field applies here as well.
805+ /// The caveat described above the `total_fee_earned_msat ` field applies here as well.
806806 outbound_amount_forwarded_msat : Option < u64 > ,
807807 } ,
808808 /// Used to indicate that a channel with the given `channel_id` is being opened and pending
@@ -1083,12 +1083,12 @@ impl Writeable for Event {
10831083 } ) ;
10841084 }
10851085 & Event :: PaymentForwarded {
1086- fee_earned_msat , prev_channel_id, claim_from_onchain_tx,
1086+ total_fee_earned_msat , prev_channel_id, claim_from_onchain_tx,
10871087 next_channel_id, outbound_amount_forwarded_msat
10881088 } => {
10891089 7u8 . write ( writer) ?;
10901090 write_tlv_fields ! ( writer, {
1091- ( 0 , fee_earned_msat , option) ,
1091+ ( 0 , total_fee_earned_msat , option) ,
10921092 ( 1 , prev_channel_id, option) ,
10931093 ( 2 , claim_from_onchain_tx, required) ,
10941094 ( 3 , next_channel_id, option) ,
@@ -1384,20 +1384,20 @@ impl MaybeReadable for Event {
13841384 } ,
13851385 7u8 => {
13861386 let f = || {
1387- let mut fee_earned_msat = None ;
1387+ let mut total_fee_earned_msat = None ;
13881388 let mut prev_channel_id = None ;
13891389 let mut claim_from_onchain_tx = false ;
13901390 let mut next_channel_id = None ;
13911391 let mut outbound_amount_forwarded_msat = None ;
13921392 read_tlv_fields ! ( reader, {
1393- ( 0 , fee_earned_msat , option) ,
1393+ ( 0 , total_fee_earned_msat , option) ,
13941394 ( 1 , prev_channel_id, option) ,
13951395 ( 2 , claim_from_onchain_tx, required) ,
13961396 ( 3 , next_channel_id, option) ,
13971397 ( 5 , outbound_amount_forwarded_msat, option) ,
13981398 } ) ;
13991399 Ok ( Some ( Event :: PaymentForwarded {
1400- fee_earned_msat , prev_channel_id, claim_from_onchain_tx, next_channel_id,
1400+ total_fee_earned_msat , prev_channel_id, claim_from_onchain_tx, next_channel_id,
14011401 outbound_amount_forwarded_msat
14021402 } ) )
14031403 } ;
0 commit comments