Skip to content

Commit

Permalink
feat: Remove delay when a package is found
Browse files Browse the repository at this point in the history
  • Loading branch information
jonathan-d-zhang committed Jul 24, 2024
1 parent 3ca4496 commit d72598e
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -73,11 +73,15 @@ fn main() -> Result<()> {
}
}

Ok(None) => info!("No job found"),
Ok(None) => {
info!("No job found");
std::thread::sleep(Duration::from_secs(APP_CONFIG.load_duration));
}

Err(err) => error!("Unexpected HTTP error: {err}"),
Err(err) => {
error!("Unexpected HTTP error: {err}");
std::thread::sleep(Duration::from_secs(APP_CONFIG.load_duration));
}
}

std::thread::sleep(Duration::from_secs(APP_CONFIG.load_duration));
}
}

0 comments on commit d72598e

Please sign in to comment.