@@ -991,7 +991,7 @@ impl<Signer: ChannelSigner> ChannelContext<Signer> {
991
991
}
992
992
993
993
/// Returns the funding_txo we either got from our peer, or were given by
994
- /// get_outbound_funding_created .
994
+ /// get_funding_created .
995
995
pub fn get_funding_txo(&self) -> Option<OutPoint> {
996
996
self.channel_transaction_parameters.funding_outpoint
997
997
}
@@ -1436,7 +1436,7 @@ impl<Signer: ChannelSigner> ChannelContext<Signer> {
1436
1436
#[inline]
1437
1437
/// Creates a set of keys for build_commitment_transaction to generate a transaction which we
1438
1438
/// will sign and send to our counterparty.
1439
- /// If an Err is returned, it is a ChannelError::Close (for get_outbound_funding_created )
1439
+ /// If an Err is returned, it is a ChannelError::Close (for get_funding_created )
1440
1440
fn build_remote_transaction_keys(&self) -> TxCreationKeys {
1441
1441
//TODO: Ensure that the payment_key derived here ends up in the library users' wallet as we
1442
1442
//may see payments to it!
@@ -2022,7 +2022,7 @@ fn commit_tx_fee_msat(feerate_per_kw: u32, num_htlcs: usize, channel_type_featur
2022
2022
2023
2023
// TODO: We should refactor this to be an Inbound/OutboundChannel until initial setup handshaking
2024
2024
// has been completed, and then turn into a Channel to get compiler-time enforcement of things like
2025
- // calling channel_id() before we're set up or things like get_outbound_funding_signed on an
2025
+ // calling channel_id() before we're set up or things like get_funding_signed on an
2026
2026
// inbound channel.
2027
2027
//
2028
2028
// Holder designates channel data owned for the benefit of the user client.
@@ -5658,8 +5658,8 @@ impl<Signer: WriteableEcdsaChannelSigner> OutboundV1Channel<Signer> {
5658
5658
})
5659
5659
}
5660
5660
5661
- /// If an Err is returned, it is a ChannelError::Close (for get_outbound_funding_created )
5662
- fn get_outbound_funding_created_signature <L: Deref>(&mut self, logger: &L) -> Result<Signature, ChannelError> where L::Target: Logger {
5661
+ /// If an Err is returned, it is a ChannelError::Close (for get_funding_created )
5662
+ fn get_funding_created_signature <L: Deref>(&mut self, logger: &L) -> Result<Signature, ChannelError> where L::Target: Logger {
5663
5663
let counterparty_keys = self.context.build_remote_transaction_keys();
5664
5664
let counterparty_initial_commitment_tx = self.context.build_commitment_transaction(self.context.cur_counterparty_commitment_transaction_number, &counterparty_keys, false, false, logger).tx;
5665
5665
Ok(self.context.holder_signer.sign_counterparty_commitment(&counterparty_initial_commitment_tx, Vec::new(), &self.context.secp_ctx)
@@ -5673,7 +5673,7 @@ impl<Signer: WriteableEcdsaChannelSigner> OutboundV1Channel<Signer> {
5673
5673
/// Note that channel_id changes during this call!
5674
5674
/// Do NOT broadcast the funding transaction until after a successful funding_signed call!
5675
5675
/// If an Err is returned, it is a ChannelError::Close.
5676
- pub fn get_outbound_funding_created <L: Deref>(mut self, funding_transaction: Transaction, funding_txo: OutPoint, logger: &L)
5676
+ pub fn get_funding_created <L: Deref>(mut self, funding_transaction: Transaction, funding_txo: OutPoint, logger: &L)
5677
5677
-> Result<(Channel<Signer>, msgs::FundingCreated), (Self, ChannelError)> where L::Target: Logger {
5678
5678
if !self.context.is_outbound() {
5679
5679
panic!("Tried to create outbound funding_created message on an inbound channel!");
@@ -5690,7 +5690,7 @@ impl<Signer: WriteableEcdsaChannelSigner> OutboundV1Channel<Signer> {
5690
5690
self.context.channel_transaction_parameters.funding_outpoint = Some(funding_txo);
5691
5691
self.context.holder_signer.provide_channel_parameters(&self.context.channel_transaction_parameters);
5692
5692
5693
- let signature = match self.get_outbound_funding_created_signature (logger) {
5693
+ let signature = match self.get_funding_created_signature (logger) {
5694
5694
Ok(res) => res,
5695
5695
Err(e) => {
5696
5696
log_error!(logger, "Got bad signatures: {:?}!", e);
@@ -7567,7 +7567,7 @@ mod tests {
7567
7567
value: 10000000, script_pubkey: output_script.clone(),
7568
7568
}]};
7569
7569
let funding_outpoint = OutPoint{ txid: tx.txid(), index: 0 };
7570
- let (mut node_a_chan, funding_created_msg) = node_a_chan.get_outbound_funding_created (tx.clone(), funding_outpoint, &&logger).map_err(|_| ()).unwrap();
7570
+ let (mut node_a_chan, funding_created_msg) = node_a_chan.get_funding_created (tx.clone(), funding_outpoint, &&logger).map_err(|_| ()).unwrap();
7571
7571
let (_, funding_signed_msg, _) = node_b_chan.funding_created(&funding_created_msg, best_block, &&keys_provider, &&logger).map_err(|_| ()).unwrap();
7572
7572
7573
7573
// Node B --> Node A: funding signed
@@ -7694,7 +7694,7 @@ mod tests {
7694
7694
value: 10000000, script_pubkey: output_script.clone(),
7695
7695
}]};
7696
7696
let funding_outpoint = OutPoint{ txid: tx.txid(), index: 0 };
7697
- let (mut node_a_chan, funding_created_msg) = node_a_chan.get_outbound_funding_created (tx.clone(), funding_outpoint, &&logger).map_err(|_| ()).unwrap();
7697
+ let (mut node_a_chan, funding_created_msg) = node_a_chan.get_funding_created (tx.clone(), funding_outpoint, &&logger).map_err(|_| ()).unwrap();
7698
7698
let (mut node_b_chan, funding_signed_msg, _) = node_b_chan.funding_created(&funding_created_msg, best_block, &&keys_provider, &&logger).map_err(|_| ()).unwrap();
7699
7699
7700
7700
// Node B --> Node A: funding signed
@@ -7882,7 +7882,7 @@ mod tests {
7882
7882
value: 10000000, script_pubkey: output_script.clone(),
7883
7883
}]};
7884
7884
let funding_outpoint = OutPoint{ txid: tx.txid(), index: 0 };
7885
- let (mut node_a_chan, funding_created_msg) = node_a_chan.get_outbound_funding_created (tx.clone(), funding_outpoint, &&logger).map_err(|_| ()).unwrap();
7885
+ let (mut node_a_chan, funding_created_msg) = node_a_chan.get_funding_created (tx.clone(), funding_outpoint, &&logger).map_err(|_| ()).unwrap();
7886
7886
let (_, funding_signed_msg, _) = node_b_chan.funding_created(&funding_created_msg, best_block, &&keys_provider, &&logger).map_err(|_| ()).unwrap();
7887
7887
7888
7888
// Node B --> Node A: funding signed
0 commit comments