X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/blobdiff_plain/e09fbb1194ebfbb3b278bae40d31c67e416cf919..c07fe122071abb897f5c40a38f86c3f651570a1d:/SL/HTML/Util.pm diff --git a/SL/HTML/Util.pm b/SL/HTML/Util.pm index 72a7a7f57..c62fd9202 100644 --- a/SL/HTML/Util.pm +++ b/SL/HTML/Util.pm @@ -17,6 +17,11 @@ sub strip { my $value = !ref($class_or_value) && (($class_or_value // '') eq 'SL::HTML::Util') ? $_[1] : $class_or_value; + return '' unless defined $value; + + # Remove HTML comments. + $value =~ s{ }{}gx; + if (!%stripper) { %stripper = ( parser => HTML::Parser->new );