Inc default interval in --rate-limit to 10ms (#804)

Signed-off-by: Jiahao XU <Jiahao_XU@outlook.com>
This commit is contained in:
Jiahao XU 2023-02-15 17:07:25 +11:00 committed by GitHub
parent 9874dca454
commit 89b920a876
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -118,7 +118,7 @@ pub struct Args {
/// Override the rate limit duration. /// Override the rate limit duration.
/// ///
/// By default, cargo-binstall allows one request per 5 ms. /// By default, cargo-binstall allows one request per 10 ms.
/// ///
/// Example: /// Example:
/// ///
@ -290,7 +290,7 @@ impl FromStr for RateLimit {
impl Default for RateLimit { impl Default for RateLimit {
fn default() -> Self { fn default() -> Self {
Self { Self {
duration: NonZeroU64::new(5).unwrap(), duration: NonZeroU64::new(10).unwrap(),
request_count: NonZeroU64::new(1).unwrap(), request_count: NonZeroU64::new(1).unwrap(),
} }
} }