FIX: Allow trailing _ because we used to.

This commit is contained in:
Robin Ward 2015-09-09 14:06:36 -04:00
parent 9548876c2d
commit b3d2982be7

View File

@ -75,7 +75,7 @@ class UsernameValidator
def username_last_char_valid?
return unless errors.empty?
if username[-1] =~ /[^A-Za-z0-9]/
if username[-1] =~ /[^A-Za-z0-9_]/
self.errors << I18n.t(:'user.username.must_end_with_alphanumeric')
end
end