def search_by_code(pattern)
      self.class.new(
        select do |emoji|
          pattern === emoji.code || emoji.aliases.any? do |alias_code|
            pattern === alias_code
          end
        end
      )
    end
def search_by_code(pattern)
      self.class.new(
        select do |emoji|
          pattern === emoji.code || emoji.aliases.any? do |alias_code|
            pattern === alias_code
          end
        end
      )
    end
Searches emojis that match with given pattern
 @param pattern [Object]
 @return [Somemoji::EmojiCollection]
 @example
   Somemoji.emoji_collection.search_by_code(/^cus/).map(&:code)
   #=> ["custard", "customs"]