From ab16fe80641689f10be3e8722d943a61044cacfc Mon Sep 17 00:00:00 2001 From: Lawson Jaglom-Kurtz Date: Thu, 20 Jan 2022 11:34:01 -0700 Subject: [PATCH] Revert 3b02b32276fab70e21a017d62ec9eea67996a906 --- lib/oktakit/response/raise_error.rb | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/oktakit/response/raise_error.rb b/lib/oktakit/response/raise_error.rb index 9175be2..5837a48 100644 --- a/lib/oktakit/response/raise_error.rb +++ b/lib/oktakit/response/raise_error.rb @@ -7,6 +7,8 @@ module Response # This class raises an Oktakit-flavored exception based # HTTP status codes returned by the API class RaiseError < Faraday::Response::Middleware + private + def on_complete(response) if (error = Oktakit::Error.from_response(response)) raise error