class Nokogiri::XML::Node

def attributes

use #attribute_nodes instead.
If you need to distinguish attributes with the same name, with different namespaces
representing the attribute.
the attribute name without any namespace, the value is a Nokogiri::XML::Attr
Returns a hash containing the node's attributes. The key is
###
def attributes
  Hash[*(attribute_nodes.map { |node|
    [node.node_name, node]
  }.flatten)]
end