Merge pull request #2842 from evazion/fix-user-name-changes

Minor user name changes improvements.
This commit is contained in:
Albert Yi
2017-01-16 11:50:51 -08:00
committed by GitHub
9 changed files with 116 additions and 66 deletions

View File

@@ -36,6 +36,10 @@ class UserNameChangeRequest < ActiveRecord::Base
def approved?
status == "approved"
end
def pending?
status == "pending"
end
def normalize_name
self.desired_name = desired_name.strip.gsub(/ /, "_")