Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Throws exception on nine-digit zip code #17

Open
mstahl opened this issue Jan 8, 2014 · 1 comment
Open

Throws exception on nine-digit zip code #17

mstahl opened this issue Jan 8, 2014 · 1 comment

Comments

@mstahl
Copy link

mstahl commented Jan 8, 2014

This is easy enough I figure I'll send you a pull request later today, but thought I'd write an issue anyway to start a discussion about this. When I send a ZIP code with a +4, e.g. "60622-1234", Area raises an ArgumentError: "You must provide a valid area or zip code". For my purposes I don't really care about the +4, so I could filter it out before asking Area, but Area really should handle these kinds of ZIP codes as they are considered to be well-formatted and are accepted by the US Postal Service as valid zip codes.

I think it would be unreasonable to ask it to know exactly where each +4 zip code is, geographically (like, lat/lng should come from the first five digits because seriously nobody should care about the last four), but including the +4 is definitely not good enough cause for throwing an exception.

@jgv
Copy link
Owner

jgv commented Jan 8, 2014

Agreed. Happy to accept a pull request for this.

On Jan 8, 2014, at 15:33, max thom stahl notifications@github.com wrote:

This is easy enough I figure I'll send you a pull request later today, but thought I'd write an issue anyway to start a discussion about this. When I send a ZIP code with a +4, e.g. "60622-1234", Area raises an ArgumentError: "You must provide a valid area or zip code". For my purposes I don't really care about the +4, so I could filter it out before asking Area, but Area really should handle these kinds of ZIP codes as they are considered to be well-formatted and are accepted by the US Postal Service as valid zip codes.

I think it would be unreasonable to ask it to know exactly where each +4 zip code is, geographically (like, lat/lng should come from the first five digits because seriously nobody should care about the last four), but including the +4 is definitely not good enough cause for throwing an exception.


Reply to this email directly or view it on GitHub.

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

No branches or pull requests

2 participants