Skip to content

Commit dc5d00e

Browse files
committed
Bump max_inbound_htlc_value_in_flight for priv. outbound channels
.. as users are confused why they can't send the full channel amount. LDK will default to this behavior soon, anyways, at which point we'll be able to drop this manual override again.
1 parent ddc6430 commit dc5d00e

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/lib.rs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1089,6 +1089,14 @@ impl Node {
10891089
let mut user_config = default_user_config(&self.config);
10901090
user_config.channel_handshake_config.announced_channel = announce_channel;
10911091
user_config.channel_config = (*(channel_config.unwrap_or_default())).clone().into();
1092+
// We set the max inflight to 100% for private channels.
1093+
// FIXME: LDK will default to this behavior soon, too, at which point we should drop this
1094+
// manual override.
1095+
if !announce_channel {
1096+
user_config
1097+
.channel_handshake_config
1098+
.max_inbound_htlc_value_in_flight_percent_of_channel = 100;
1099+
}
10921100

10931101
let push_msat = push_to_counterparty_msat.unwrap_or(0);
10941102
let user_channel_id: u128 = rand::thread_rng().gen::<u128>();

0 commit comments

Comments
 (0)