Make stop_gap a parameter to EsploraBlockchainConfig::new

This commit is contained in:
LLFourn 2021-11-05 13:34:30 +11:00
parent 0f0a01a742
commit 9c5770831d
No known key found for this signature in database
GPG Key ID: A27093B54DA11F65

View File

@ -127,12 +127,12 @@ pub struct EsploraBlockchainConfig {
impl EsploraBlockchainConfig {
/// create a config with default values given the base url and stop gap
pub fn new(base_url: String) -> Self {
pub fn new(base_url: String, stop_gap: usize) -> Self {
Self {
base_url,
proxy: None,
timeout: None,
stop_gap: 20,
stop_gap,
concurrency: None,
}
}