Skip to content

Commit 2ea995c

Browse files
committed
Add details about request to exception
When we get a generic error from the auth API include some details about the request when creating the exception.
1 parent ba0fd66 commit 2ea995c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/kracken/token_authenticator.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ def fetch(token)
1212
elsif response.status == 404
1313
raise TokenUnauthorized, "Invalid credentials"
1414
elsif !response.success?
15-
raise RequestError
15+
raise RequestError, "Token Authentication Failed. Status: #{response.status} token: #{token}"
1616
end
1717

1818
self

0 commit comments

Comments
 (0)