lib/notion/faraday/response/raise_error.rb in notion-ruby-client-1.0.0 vs lib/notion/faraday/response/raise_error.rb in notion-ruby-client-1.1.0

- old
+ new

@@ -1,10 +1,10 @@ # frozen_string_literal: true module Notion module Faraday module Response - class RaiseError < ::Faraday::Response::Middleware + class RaiseError < ::Faraday::Response::Json def on_complete(env) raise Notion::Api::Errors::TooManyRequests, env.response if env.status == 429 return if env.success? @@ -26,6 +26,6 @@ raise Notion::Api::Errors::ParsingError.new('parsing_error', env.response) end end end end -end \ No newline at end of file +end