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

Remove user-specified delimiter from start when no area code is present (in number_to_phone) #3314

Merged
merged 1 commit into from
Oct 13, 2011

Conversation

macmartine
Copy link
Contributor

Previously, specifying a delimiter to number_to_phone when no area code is present would result in the delimiter at the start of the resulting phone number:

For example:

number_to_phone("5550000", :delimiter => ".")
would become: .555.0000
but should be: 555.0000

(notice, the leading '.')

This pull request fixes that. All existing tests pass and new test added.

spastorino added a commit that referenced this pull request Oct 13, 2011
Remove user-specified delimiter from start when no area code is present (in number_to_phone)
@spastorino spastorino merged commit a5b0f91 into rails:master Oct 13, 2011
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.

None yet

2 participants