user/dev discussion of public-inbox itself
 help / color / Atom feed
From: Kyle Meyer <>
Cc: Kyle Meyer <>
Subject: [PATCH 2/2] view: actually omit subject text when dumping topics
Date: Tue, 21 Apr 2020 21:33:59 -0400
Message-ID: <> (raw)
In-Reply-To: <>

Despite dump_topics() calling dedupe_subject() on the subject, the
index shows partly duplicated subjects, for example

  ` [PATCH 2/2] t/www_listing: avoid 'once' warnings
    ` [PATCH v2] t/www_listing: avoid 'once' warnings "

In the second line, the omission character " is appended, but the
entire subject is shown.  To display the subject with duplicated parts
omitted, regenerate it from the array that is modified by
 lib/PublicInbox/ | 1 +
 1 file changed, 1 insertion(+)

diff --git a/lib/PublicInbox/ b/lib/PublicInbox/
index c90eaf6a..30928fdb 100644
--- a/lib/PublicInbox/
+++ b/lib/PublicInbox/
@@ -1096,6 +1096,7 @@ sub dump_topics {
 			my @next_prev = @subj; # full copy
 			my $omit = dedupe_subject($prev_subj, \@subj, ' &#34;');
 			$prev_subj = \@next_prev;
+			$subj = join(' ', @subj);
 			$subj = ascii_html($subj);
 			obfuscate_addrs($obfs_ibx, $subj) if $obfs_ibx;
 			$href = mid_href($mid);

      parent reply index

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-22  1:33 [PATCH 0/2] view: two display fixes for deduped subjects Kyle Meyer
2020-04-22  1:33 ` [PATCH 1/2] view: strip omission character from current message in thread view Kyle Meyer
2020-04-22  7:01   ` Eric Wong
2020-04-22 15:44     ` Kyle Meyer
2020-04-22  1:33 ` Kyle Meyer [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:

  List information:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \ \ \ \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

user/dev discussion of public-inbox itself

Archives are clonable:
	git clone --mirror
	git clone --mirror http://czquwvybam4bgbro.onion/meta
	git clone --mirror http://hjrcffqmbrq6wope.onion/meta
	git clone --mirror http://ou63pmih66umazou.onion/meta

Example config snippet for mirrors

Newsgroups are available over NNTP:

 note: .onion URLs require Tor:

AGPL code for this site: git clone