added attr_accessor and validates_uniqueness to user.rb