Sha256: 61187bcb49a89f2a8b97621966901fb8ce6b399891955875ac5129c47ed24d6a

Contents?: true

Size: 484 Bytes

Versions: 16

Compression:

Stored size: 484 Bytes

Contents

module DropboxApi::Errors
  class TooManyRequestsError < BasicError; end
  class TooManyWriteOperationsError < TooManyRequestsError; end

  class TooManyRequestsError
    attr_accessor :retry_after

    def self.build(message, metadata)
      subtype, metadata = find_subtype metadata

      subtype.new(message, metadata)
    end

    ErrorSubtypes = {
      :too_many_requests => TooManyRequestsError,
      :too_many_write_operations => TooManyWriteOperationsError
    }
  end
end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
dropbox_api-0.1.18 lib/dropbox_api/errors/too_many_requests_error.rb
dropbox_api-0.1.17 lib/dropbox_api/errors/too_many_requests_error.rb
dropbox_api-0.1.16 lib/dropbox_api/errors/too_many_requests_error.rb
dropbox_api-0.1.15 lib/dropbox_api/errors/too_many_requests_error.rb
dropbox_api-0.1.14 lib/dropbox_api/errors/too_many_requests_error.rb
dropbox_api-0.1.13 lib/dropbox_api/errors/too_many_requests_error.rb
dropbox_api-0.1.12 lib/dropbox_api/errors/too_many_requests_error.rb
dropbox_api-0.1.11 lib/dropbox_api/errors/too_many_requests_error.rb
dropbox_api-0.1.10 lib/dropbox_api/errors/too_many_requests_error.rb
dropbox_api-0.1.9 lib/dropbox_api/errors/too_many_requests_error.rb
dropbox_api-0.1.8 lib/dropbox_api/errors/too_many_requests_error.rb
dropbox_api-0.1.7 lib/dropbox_api/errors/too_many_requests_error.rb
dropbox_api-0.1.6 lib/dropbox_api/errors/too_many_requests_error.rb
dropbox_api-0.1.5 lib/dropbox_api/errors/too_many_requests_error.rb
dropbox_api-0.1.4 lib/dropbox_api/errors/too_many_requests_error.rb
dropbox_api-0.1.3 lib/dropbox_api/errors/too_many_requests_error.rb