Refactor a little
Refactor user.rb by using class methods