def decode(elements)
      elements.each do |element|

        # Remove elements with CSS style "none"
        if !TAGS.include?(element.name) || (element["style"] && element["style"] =~ /none/)
          element.children.remove

        # Get rid of decoy children
        elsif element["class"]
          decoys.each do |decoy|
            element.children.remove if decoy.include?(element["class"])
          end
        end
      end

      elements
    end
def decode(elements)
      elements.each do |element|

        # Remove elements with CSS style "none"
        if !TAGS.include?(element.name) || (element["style"] && element["style"] =~ /none/)
          element.children.remove

        # Get rid of decoy children
        elsif element["class"]
          decoys.each do |decoy|
            element.children.remove if decoy.include?(element["class"])
          end
        end
      end

      elements
    end
Receives an array of elements
 and returns another without invisibles.