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

Extension example in README does not work #155

Closed
derekprior opened this issue Jan 13, 2017 · 2 comments
Closed

Extension example in README does not work #155

derekprior opened this issue Jan 13, 2017 · 2 comments

Comments

@derekprior
Copy link

derekprior commented Jan 13, 2017

From the README:

Validation supports phone numbers with extension, such as +18181231234 x1234 or '+1 (818)151-5483 #4312' out-of-the-box.

In my app:

class Address
  validates :phone_number, phony_plausible: true
  validates :fax_number, phony_plausible: true

  phony_normalize :phone_number, default_country_code: 'US'
  phony_normalize :fax_number, default_country_code: 'US'
end

In console:

address = Address.new(phone_number: '+18181231234 x1234')
address.valid? # false
address.errors.full_messages # ["Phone number is an invalid number"]
@derekprior
Copy link
Author

It looks like the change that added this functionality is not released on RubyGems. This works if I pull the GitHub version of the gem. Any chance you could push the updated gem to eliminate this confusion?

@ollym
Copy link

ollym commented Feb 9, 2017

This has now been done, you can close this issue

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