Subject: | getAttributes() null reference in hash dereference at line 2509 (with fix) |
Xpath.pm's getAttributes() warns about a null reference in hash
dereference if $node->atts(@_) returns an empty list or undef.
The following "|| {}" work-around prevents this warning:
sub getAttributes
{
my $node = shift;
return %{$node->atts(@_) || {}};
}