We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7cf88e8 commit fa3ea56Copy full SHA for fa3ea56
lightning/src/ln/channel.rs
@@ -4469,11 +4469,7 @@ impl<SP: Deref> ChannelContext<SP> where SP::Target: SignerProvider {
4469
4470
#[allow(deprecated)] // TODO: Remove once balance_msat is removed.
4471
AvailableBalances {
4472
- inbound_capacity_msat: cmp::max(funding.get_value_satoshis() as i64 * 1000
4473
- - funding.value_to_self_msat as i64
4474
- - htlc_stats.pending_inbound_htlcs_value_msat as i64
4475
- - funding.holder_selected_channel_reserve_satoshis as i64 * 1000,
4476
- 0) as u64,
+ inbound_capacity_msat: remote_balance_before_fee_msat.saturating_sub(funding.holder_selected_channel_reserve_satoshis * 1000),
4477
outbound_capacity_msat,
4478
next_outbound_htlc_limit_msat: available_capacity_msat,
4479
next_outbound_htlc_minimum_msat,
0 commit comments