Exception: DiscordRDA::ScalableRestClient::RateLimitedError
- Inherits:
-
APIError
- Object
- StandardError
- APIError
- DiscordRDA::ScalableRestClient::RateLimitedError
- Defined in:
- lib/discord_rda/connection/scalable_rest_client.rb
Instance Attribute Summary collapse
-
#retry_after ⇒ Object
readonly
Returns the value of attribute retry_after.
Attributes inherited from APIError
Instance Method Summary collapse
-
#initialize(status, data, retry_after: nil) ⇒ RateLimitedError
constructor
A new instance of RateLimitedError.
Constructor Details
#initialize(status, data, retry_after: nil) ⇒ RateLimitedError
Returns a new instance of RateLimitedError.
518 519 520 521 |
# File 'lib/discord_rda/connection/scalable_rest_client.rb', line 518 def initialize(status, data, retry_after: nil) super(status, data) @retry_after = retry_after || data['retry_after'] || 1.0 end |
Instance Attribute Details
#retry_after ⇒ Object (readonly)
Returns the value of attribute retry_after.
516 517 518 |
# File 'lib/discord_rda/connection/scalable_rest_client.rb', line 516 def retry_after @retry_after end |