You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For now, when geocoding request have response status ZERO_RESULTS, it is considered as error.
Looks really strange, since it is not an error.
On such response status my service will response 204 for example.
When status 'OK' - then just response 200
In another cases it is really error and I want log it and response 500
I see only one way to achieve it - 'if err != nil && err == "maps: ZERO_RESULTS - "' and it is really ugly.
I have call "result, err := c.Geocode(context.Background(), r)". Any idea how to make it not so ugly?
For me more natural looks PR to Geocode func, that will check if response status "ZERO_RESULTS", than just return empty results. Is such PR have change to be merged, since it will broke backward compatibility?
The text was updated successfully, but these errors were encountered:
For now, when geocoding request have response status ZERO_RESULTS, it is considered as error.
Looks really strange, since it is not an error.
On such response status my service will response 204 for example.
When status 'OK' - then just response 200
In another cases it is really error and I want log it and response 500
I see only one way to achieve it - 'if err != nil && err == "maps: ZERO_RESULTS - "' and it is really ugly.
I have call "result, err := c.Geocode(context.Background(), r)". Any idea how to make it not so ugly?
For me more natural looks PR to Geocode func, that will check if response status "ZERO_RESULTS", than just return empty results. Is such PR have change to be merged, since it will broke backward compatibility?
The text was updated successfully, but these errors were encountered: