diff --git a/app/models/user.rb b/app/models/user.rb index 6b8bf0d..4ec3546 100644 --- a/app/models/user.rb +++ b/app/models/user.rb @@ -30,7 +30,7 @@ class User < ActiveRecord::Base with_options :allow_blank => true do |u| u.validates_length_of :name, :city, :github, :in => 1..255 u.validates_format_of :email, :with => /\A([^@\s]+)@((?:[-a-z0-9]+\.)+[a-z]{2,})\Z/i - u.validates_format_of :github, :with => /^[a-z_]+$/ + u.validates_format_of :github, :with => /^[a-z_0-9]+$/ u.validates_uniqueness_of :email, :github, :case_sensitive => false end