X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=blobdiff_plain;f=src%2Fln%2Fchannel.rs;h=1b7db97d3d342d1a97551b3a274c37425a07d8a2;hb=df88525d44563e44201bbfd745ffc57614f14c30;hp=5c861b2eae7b4dec8293815fdab53f28535c79eb;hpb=b4299bcc9ace423bba2fcb708bd4a5f8661d5278;p=rust-lightning diff --git a/src/ln/channel.rs b/src/ln/channel.rs index 5c861b2e..1b7db97d 100644 --- a/src/ln/channel.rs +++ b/src/ln/channel.rs @@ -1960,10 +1960,12 @@ impl Channel { if !self.channel_outbound { panic!("Cannot send fee from inbound channel"); } - if !self.is_usable() { panic!("Cannot update fee until channel is fully established and we haven't started shutting down"); } + if !self.is_live() { + panic!("Cannot update fee while peer is disconnected (ChannelManager should have caught this)"); + } if (self.channel_state & (ChannelState::AwaitingRemoteRevoke as u32)) == (ChannelState::AwaitingRemoteRevoke as u32) { self.holding_cell_update_fee = Some(feerate_per_kw);