Skip to content

Conversation

sbscully
Copy link
Collaborator

  • Currently if an invalid location/query is passed to the OpenCage::Geocoder#geocode method it will still make a request to the OpenCage API and it might not be immediately clear that the arguments were invalid.
  • Throws an OpenCage::Error::InvalidRequest if anything other than a string is passed for the query/location.

@sbscully sbscully requested a review from mtmail September 27, 2025 12:21
@sbscully sbscully self-assigned this Sep 27, 2025
@mtmail mtmail merged commit 4f5b1c9 into master Oct 2, 2025
8 checks passed
@mtmail
Copy link
Member

mtmail commented Oct 2, 2025

I had to double-check what happens if the query is nil because that's not a String type either. The library already raised the same error so the change is backward compatible.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants