Skip to content
Snippets Groups Projects
Commit 7ca2e8a8 authored by Alex Reisner's avatar Alex Reisner
Browse files

Raise exception on HTTP 429 Too Many Requests.

parent a19fb0aa
No related branches found
No related tags found
No related merge requests found
......@@ -249,6 +249,9 @@ module Geocoder
elsif response.code.to_i == 402
raise_error(Geocoder::OverQueryLimitError) ||
warn("Geocoding API error: 402 Payment Required")
elsif response.code.to_i == 429
raise_error(Geocoder::OverQueryLimitError) ||
warn("Geocoding API error: 429 Too Many Requests")
end
end
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment