From 09df1a47cf0e0fbb1e49597326c1ab7735ec63f9 Mon Sep 17 00:00:00 2001 From: Hakan Ensari Date: Fri, 13 Dec 2024 18:21:51 +0100 Subject: [PATCH] Rename method argument for clarity --- lib/peddler/api.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/peddler/api.rb b/lib/peddler/api.rb index c72f8d40..91f2d7c8 100644 --- a/lib/peddler/api.rb +++ b/lib/peddler/api.rb @@ -66,12 +66,12 @@ def http # Throttles with a rate limit and retries when the API returns a 429 # - # @param [Float] rate_limit The delay in seconds before retrying + # @param [Float] requests_per_second # @return [self] - def meter(rate_limit) + def meter(requests_per_second) # HTTP v6.0 will implement retriable. Until then, point to their GitHub repo, or it's a no-op. # https://github.com/httprb/http/pull/790 - delay = sandbox? ? 0.2 : 1.0 / rate_limit + delay = sandbox? ? 0.2 : 1.0 / requests_per_second retriable(delay: delay, tries: 3, retry_statuses: [429]) self