Skip to content

Commit

Permalink
remove assert
Browse files Browse the repository at this point in the history
  • Loading branch information
alexanderwiederin committed Nov 13, 2023
1 parent ac5b165 commit b26d129
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -151,6 +151,7 @@ use bitcoin::{Address, Txid};

use rand::Rng;

use crate::NodeError::InvalidSocketAddress;
use std::default::Default;
use std::net::{SocketAddr, ToSocketAddrs};
use std::sync::{Arc, Mutex, RwLock};
Expand Down Expand Up @@ -506,13 +507,11 @@ impl<K: KVStore + Sync + Send + 'static> Node<K> {
"Unable to resolve listing address: {:?}",
socket_address
);
Error::InvalidSocketAddress
InvalidSocketAddress
})
})
.flatten()
.collect::<Vec<SocketAddr>>();

assert!(!collected_addrs.is_empty());
.collect();

let bind_addrs: Arc<[SocketAddr]> = collected_addrs.clone().into();

Expand Down

0 comments on commit b26d129

Please sign in to comment.