Class: Veryfi::Error
- Inherits:
-
Object
show all
- Defined in:
- lib/veryfi/error.rb
Defined Under Namespace
Classes: AccessLimitReached, BadRequest, InternalError, ResourceNotFound, UnauthorizedAccessToken, UnexpectedHTTPMethod, VeryfiError
Class Method Summary
collapse
Class Method Details
.from_response(status, response) ⇒ Object
5
6
7
8
9
10
11
|
# File 'lib/veryfi/error.rb', line 5
def self.from_response(status, response)
if response.empty?
VeryfiError.new(format("%<code>d", code: status))
else
get_error(status, response)
end
end
|
.get_error(status, response) ⇒ Object