From 1151816fc42c7d69c2417d58abb31d214ad06780 Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Wed, 2 Sep 2015 02:37:22 +0000 Subject: view: avoid links to unknown compressed Message-IDs Compressed Message-IDs are irreversible and may not be used at other sites. So avoid compressing Message-IDs we do not know about so users have a chance of finding the message in other archives by doing a Message-ID lookup. --- lib/PublicInbox/Hval.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/PublicInbox/Hval.pm') diff --git a/lib/PublicInbox/Hval.pm b/lib/PublicInbox/Hval.pm index 21efe40e..0445e575 100644 --- a/lib/PublicInbox/Hval.pm +++ b/lib/PublicInbox/Hval.pm @@ -25,9 +25,9 @@ sub new { } sub new_msgid { - my ($class, $msgid) = @_; + my ($class, $msgid, $no_compress) = @_; $msgid = mid_clean($msgid); - $class->new($msgid, mid_compress($msgid)); + $class->new($msgid, $no_compress ? $msgid : mid_compress($msgid)); } sub new_oneline { -- cgit v1.2.3-24-ge0c7