Skip to content

Commit

Permalink
f Move final cltv const to spontaneous.rs
Browse files Browse the repository at this point in the history
  • Loading branch information
tnull committed Aug 28, 2024
1 parent d095d15 commit 775f8b9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
3 changes: 0 additions & 3 deletions src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,6 @@ pub(crate) const DEFAULT_ESPLORA_SERVER_URL: &str = "https://blockstream.info/ap
// The default Esplora client timeout we're using.
pub(crate) const DEFAULT_ESPLORA_CLIENT_TIMEOUT_SECS: u64 = 10;

// The default `final_cltv_expiry_delta` we apply when not set via the invoice.
pub(crate) const LDK_DEFAULT_FINAL_CLTV_EXPIRY_DELTA: u32 = 144;

// The timeout after which we abandon retrying failed payments.
pub(crate) const LDK_PAYMENT_RETRY_TIMEOUT: Duration = Duration::from_secs(10);

Expand Down
5 changes: 4 additions & 1 deletion src/payment/spontaneous.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//! Holds a payment handler allowing to send spontaneous ("keysend") payments.

use crate::config::{Config, LDK_DEFAULT_FINAL_CLTV_EXPIRY_DELTA, LDK_PAYMENT_RETRY_TIMEOUT};
use crate::config::{Config, LDK_PAYMENT_RETRY_TIMEOUT};
use crate::error::Error;
use crate::logger::{log_error, log_info, FilesystemLogger, Logger};
use crate::payment::store::{
Expand All @@ -18,6 +18,9 @@ use bitcoin::secp256k1::PublicKey;

use std::sync::{Arc, RwLock};

// The default `final_cltv_expiry_delta` we apply when not set.
const LDK_DEFAULT_FINAL_CLTV_EXPIRY_DELTA: u32 = 144;

/// A payment handler allowing to send spontaneous ("keysend") payments.
///
/// Should be retrieved by calling [`Node::spontaneous_payment`].
Expand Down

0 comments on commit 775f8b9

Please sign in to comment.