]> Sergey Matveev's repositories - public-inbox.git/commitdiff
view: preserve attribution for current message
authorEric Wong <e@80x24.org>
Thu, 7 Jul 2016 02:32:23 +0000 (02:32 +0000)
committerEric Wong <e@80x24.org>
Thu, 7 Jul 2016 02:32:23 +0000 (02:32 +0000)
It should be harmless if the "[this message]" text goes past
the boundary as we bold the entire line to make it stand out.

lib/PublicInbox/View.pm

index 7be72cfc642d19995f6d78cd29ac57700b07bc7f..f47ecba0ae27b8eb364f5842ea113774a32f78aa 100644 (file)
@@ -735,16 +735,13 @@ sub _skel_header {
 
        if ($attr ne $ctx->{prev_attr} || $ctx->{prev_level} > $level) {
                $ctx->{prev_attr} = $attr;
-       } else {
-               $attr = '';
        }
        $ctx->{prev_level} = $level;
 
        if ($cur) {
                if ($cur eq $mid) {
                        delete $ctx->{cur};
-                       $$dst .= $d;
-                       $$dst .= "<b><a\nid=r\nhref=\"#t\">".
+                       $$dst .= "<b>$d<a\nid=r\nhref=\"#t\">".
                                 "$attr [this message]</a></b>\n";
                        return;
                }