We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 38fbeb0 commit 0129593Copy full SHA for 0129593
src/utils.rs
@@ -9,7 +9,7 @@ pub async fn get_all_ipv4() -> Result<Vec<String>, Box<dyn std::error::Error>> {
9
let file = std::fs::File::open("cloudflare_ipv4.txt").unwrap();
10
let mut reader: std::io::BufReader<std::fs::File> = std::io::BufReader::new(file);
11
reader.read_to_string(&mut cidr_strings).unwrap();
12
- let cidr_list = cidr_strings.split("\n");
+ let cidr_list = cidr_strings.lines();
13
let mut ipv4_addresses = Vec::<String>::new();
14
for cidr in cidr_list {
15
let network: Ipv4Network = cidr.parse().unwrap();
0 commit comments