Subject: | Undef warnings all over the error.log |
Add "next unless defined;" in the process key loops to make sure operations are not performed on undefined values:
for ( @$ref ) {
if ( $is_hash ) {
for ( @$_{ @n } ) {
next unless defined;
encode_entities $_;
s/\r?\n/<br>/g;
}
for ( @$_{ @t } ) {
next unless defined;
$_ = localtime $_
if defined and length;
}
}
else {
for ( @$_[ @n ] ) {
next unless defined;
encode_entities $_;
s/\r?\n/<br>/g;
}
for ( @$_[ @t ] ) {
$_ = localtime $_
if defined and length;
}
}
}