@@ -995,7 +995,7 @@ impl<Signer: ChannelSigner> ChannelContext<Signer> {
995
995
}
996
996
997
997
/// Returns the funding_txo we either got from our peer, or were given by
998
- /// get_outbound_funding_created .
998
+ /// get_funding_created .
999
999
pub fn get_funding_txo(&self) -> Option<OutPoint> {
1000
1000
self.channel_transaction_parameters.funding_outpoint
1001
1001
}
@@ -1440,7 +1440,7 @@ impl<Signer: ChannelSigner> ChannelContext<Signer> {
1440
1440
#[inline]
1441
1441
/// Creates a set of keys for build_commitment_transaction to generate a transaction which we
1442
1442
/// will sign and send to our counterparty.
1443
- /// If an Err is returned, it is a ChannelError::Close (for get_outbound_funding_created )
1443
+ /// If an Err is returned, it is a ChannelError::Close (for get_funding_created )
1444
1444
fn build_remote_transaction_keys(&self) -> TxCreationKeys {
1445
1445
//TODO: Ensure that the payment_key derived here ends up in the library users' wallet as we
1446
1446
//may see payments to it!
@@ -2026,7 +2026,7 @@ fn commit_tx_fee_msat(feerate_per_kw: u32, num_htlcs: usize, channel_type_featur
2026
2026
2027
2027
// TODO: We should refactor this to be an Inbound/OutboundChannel until initial setup handshaking
2028
2028
// has been completed, and then turn into a Channel to get compiler-time enforcement of things like
2029
- // calling channel_id() before we're set up or things like get_outbound_funding_signed on an
2029
+ // calling channel_id() before we're set up or things like get_funding_signed on an
2030
2030
// inbound channel.
2031
2031
//
2032
2032
// Holder designates channel data owned for the benefit of the user client.
@@ -5662,8 +5662,8 @@ impl<Signer: WriteableEcdsaChannelSigner> OutboundV1Channel<Signer> {
5662
5662
})
5663
5663
}
5664
5664
5665
- /// If an Err is returned, it is a ChannelError::Close (for get_outbound_funding_created )
5666
- fn get_outbound_funding_created_signature <L: Deref>(&mut self, logger: &L) -> Result<Signature, ChannelError> where L::Target: Logger {
5665
+ /// If an Err is returned, it is a ChannelError::Close (for get_funding_created )
5666
+ fn get_funding_created_signature <L: Deref>(&mut self, logger: &L) -> Result<Signature, ChannelError> where L::Target: Logger {
5667
5667
let counterparty_keys = self.context.build_remote_transaction_keys();
5668
5668
let counterparty_initial_commitment_tx = self.context.build_commitment_transaction(self.context.cur_counterparty_commitment_transaction_number, &counterparty_keys, false, false, logger).tx;
5669
5669
Ok(self.context.holder_signer.sign_counterparty_commitment(&counterparty_initial_commitment_tx, Vec::new(), &self.context.secp_ctx)
@@ -5677,7 +5677,7 @@ impl<Signer: WriteableEcdsaChannelSigner> OutboundV1Channel<Signer> {
5677
5677
/// Note that channel_id changes during this call!
5678
5678
/// Do NOT broadcast the funding transaction until after a successful funding_signed call!
5679
5679
/// If an Err is returned, it is a ChannelError::Close.
5680
- pub fn get_outbound_funding_created <L: Deref>(mut self, funding_transaction: Transaction, funding_txo: OutPoint, logger: &L)
5680
+ pub fn get_funding_created <L: Deref>(mut self, funding_transaction: Transaction, funding_txo: OutPoint, logger: &L)
5681
5681
-> Result<(Channel<Signer>, msgs::FundingCreated), (Self, ChannelError)> where L::Target: Logger {
5682
5682
if !self.context.is_outbound() {
5683
5683
panic!("Tried to create outbound funding_created message on an inbound channel!");
@@ -5694,7 +5694,7 @@ impl<Signer: WriteableEcdsaChannelSigner> OutboundV1Channel<Signer> {
5694
5694
self.context.channel_transaction_parameters.funding_outpoint = Some(funding_txo);
5695
5695
self.context.holder_signer.provide_channel_parameters(&self.context.channel_transaction_parameters);
5696
5696
5697
- let signature = match self.get_outbound_funding_created_signature (logger) {
5697
+ let signature = match self.get_funding_created_signature (logger) {
5698
5698
Ok(res) => res,
5699
5699
Err(e) => {
5700
5700
log_error!(logger, "Got bad signatures: {:?}!", e);
@@ -7571,7 +7571,7 @@ mod tests {
7571
7571
value: 10000000, script_pubkey: output_script.clone(),
7572
7572
}]};
7573
7573
let funding_outpoint = OutPoint{ txid: tx.txid(), index: 0 };
7574
- let (mut node_a_chan, funding_created_msg) = node_a_chan.get_outbound_funding_created (tx.clone(), funding_outpoint, &&logger).map_err(|_| ()).unwrap();
7574
+ let (mut node_a_chan, funding_created_msg) = node_a_chan.get_funding_created (tx.clone(), funding_outpoint, &&logger).map_err(|_| ()).unwrap();
7575
7575
let (_, funding_signed_msg, _) = node_b_chan.funding_created(&funding_created_msg, best_block, &&keys_provider, &&logger).map_err(|_| ()).unwrap();
7576
7576
7577
7577
// Node B --> Node A: funding signed
@@ -7698,7 +7698,7 @@ mod tests {
7698
7698
value: 10000000, script_pubkey: output_script.clone(),
7699
7699
}]};
7700
7700
let funding_outpoint = OutPoint{ txid: tx.txid(), index: 0 };
7701
- let (mut node_a_chan, funding_created_msg) = node_a_chan.get_outbound_funding_created (tx.clone(), funding_outpoint, &&logger).map_err(|_| ()).unwrap();
7701
+ let (mut node_a_chan, funding_created_msg) = node_a_chan.get_funding_created (tx.clone(), funding_outpoint, &&logger).map_err(|_| ()).unwrap();
7702
7702
let (mut node_b_chan, funding_signed_msg, _) = node_b_chan.funding_created(&funding_created_msg, best_block, &&keys_provider, &&logger).map_err(|_| ()).unwrap();
7703
7703
7704
7704
// Node B --> Node A: funding signed
@@ -7886,7 +7886,7 @@ mod tests {
7886
7886
value: 10000000, script_pubkey: output_script.clone(),
7887
7887
}]};
7888
7888
let funding_outpoint = OutPoint{ txid: tx.txid(), index: 0 };
7889
- let (mut node_a_chan, funding_created_msg) = node_a_chan.get_outbound_funding_created (tx.clone(), funding_outpoint, &&logger).map_err(|_| ()).unwrap();
7889
+ let (mut node_a_chan, funding_created_msg) = node_a_chan.get_funding_created (tx.clone(), funding_outpoint, &&logger).map_err(|_| ()).unwrap();
7890
7890
let (_, funding_signed_msg, _) = node_b_chan.funding_created(&funding_created_msg, best_block, &&keys_provider, &&logger).map_err(|_| ()).unwrap();
7891
7891
7892
7892
// Node B --> Node A: funding signed
0 commit comments