1
Fork 0

Sleep directly after HTTP requests.

This commit is contained in:
Bauke 2022-09-22 12:36:51 +02:00
parent 1e9aa887f7
commit f49e12db37
Signed by: Bauke
GPG Key ID: C1C0F29952BCF558
1 changed files with 1 additions and 1 deletions

View File

@ -110,6 +110,7 @@ fn main() -> Result<()> {
.contains(&potential_feed.option)
{
let response = ureq_agent.get(&potential_feed.url).call()?;
sleep(timeout);
if response.content_type() == "text/xml" {
let body = response.into_string()?;
let title_start = body.find("<title>").unwrap() + 7;
@ -126,7 +127,6 @@ fn main() -> Result<()> {
};
feeds_to_output.push(potential_feed);
sleep(timeout);
progress.inc(1);
}
} else {