From 61c44bbd8e57c719a1a4de75a1a11c412173e820 Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Tue, 9 Jan 2024 12:49:13 +0000 Subject: address: avoid [ undef, undef ] address pairs For totally bogus things in address fields, we'll fall back to showing the original entry in the name column when using Email::Address::XS. The pure Perl version differs here, but we'll just let them be different when it comes to handling bogus data. --- lib/PublicInbox/View.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/PublicInbox/View.pm') diff --git a/lib/PublicInbox/View.pm b/lib/PublicInbox/View.pm index 39ec35c3..9d4262c1 100644 --- a/lib/PublicInbox/View.pm +++ b/lib/PublicInbox/View.pm @@ -230,7 +230,7 @@ sub to_cc_html ($$$$) { } } $line_len += length($n); - $url = $addr2url->{lc $pair->[1]}; + $url = $addr2url->{lc($pair->[1] // '')}; $html .= $url ? qq($n) : $n; } ($html, $len + $line_len); -- cgit v1.2.3-24-ge0c7