I agree. Unless Rails has a helper for validating all phone numbers.
On Apr 2, 2013 4:22 PM, "Chunjie" <notifications@github.com> wrote:

> In app/models/candidate.rb:
>
> > @@ -1,9 +1,13 @@
> >  class Candidate < ActiveRecord::Base
> >    attr_accessible :name, :email, :phone, :source, :description, :resume
> >
> > +  phone_format = Regexp.new("(\\d{11})|^((\\d{7,8})|(\\d{4}|\\d{3})-(\\d{7,8})|(\\d{4}|\\d{3})-(\\d{7,8})-(\\d{4}|\\d{3}|\\d{2}|\\d{1})|(\\d{7,8})-(\\d{4}|\\d{3}|\\d{2}|\\d{1}))$")
>
> It seems that the regular expression is too strict. We only need to make
> sure there are digital and dash character in the phone number string.
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/vmw-tmpst/heroapp-LetsHire/pull/56/files#r3613933>
> .
>