]> Sergey Matveev's repositories - public-inbox.git/blobdiff - lib/PublicInbox/View.pm
view: _th_index_lite: avoid one s///, improve symmetry
[public-inbox.git] / lib / PublicInbox / View.pm
index 0fe645ca41cea86834970856145f27f20b899abb..3282d4f993edc6281c75ac00127e40f8f5a359d4 100644 (file)
@@ -335,10 +335,10 @@ sub _th_index_lite {
        }
        my $s_s = nr_to_s($nr_s, 'sibling', 'siblings');
        my $s_c = nr_to_s($nr_c, 'reply', 'replies');
-       $attr =~ s!\n\z!</b>\n!s;
+       chop $attr; # remove "\n"
        $attr =~ s!<a\nhref.*</a> (?:&#34; )?!!s; # no point in dup subject
        $attr =~ s!<a\nhref=[^>]+>([^<]+)</a>!$1!s; # no point linking to self
-       $rv .= "<b>@ $attr";
+       $rv .= "<b>@ $attr</b>\n";
        if ($nr_c) {
                my $cmid = $children->[0] ? $children->[0]->{mid} : undef;
                $rv .= $pad . _skel_hdr($mapping, $cmid);