Exception: GetYourRep::Errors::AddressError
- Inherits:
-
ArgumentError
- Object
- ArgumentError
- GetYourRep::Errors::AddressError
- Defined in:
- lib/get_your_rep/errors.rb
Overview
Errors for invalid or inadequate addresses.
Instance Method Summary collapse
-
#invalid_address_type ⇒ Object
Raise when the address is not a string or an integer.
-
#reps_not_found ⇒ Object
Raise when a rep cannot be found with the given parameters.
Instance Method Details
#invalid_address_type ⇒ Object
Raise when the address is not a string or an integer. Supports integers for zip codes.
9 10 11 |
# File 'lib/get_your_rep/errors.rb', line 9 def invalid_address_type 'Entry must be of types String or Integer' end |
#reps_not_found ⇒ Object
Raise when a rep cannot be found with the given parameters.
14 15 16 17 |
# File 'lib/get_your_rep/errors.rb', line 14 def reps_not_found "Error message received. Some reps were not found. Confirm your address and check your parameters. \ Try a full address if you used a zip." end |