about summary refs log tree commit homepage
path: root/lib/PublicInbox/Hval.pm
diff options
authorEric Wong <e@80x24.org>2015-09-03 03:00:28 +0000
committerEric Wong <e@80x24.org>2015-09-03 03:06:00 +0000
commit43238d3688a51d98ce47151173aa7971e231a3bb (patch)
treeb1fc31be8763eefcc2393d1fa44ad75581059fa1 /lib/PublicInbox/Hval.pm
parent793da75fbcb5a2c546b3d582f39761fff3d8292d (diff)
Provide a fallback for legacy SHA-1 messages, but do not
advertise shorter URLs anymore for data portability concerns.

This fixes a regression introduced in
commit 81a9c1b476987d845b340ab9013d26cf4487cb9a
("search: disable Message-ID compression in Xapian")
which ended up breaking thread-related endpoints for
large Message-IDs, as lookups on the SHA-1 message no longer
Diffstat (limited to 'lib/PublicInbox/Hval.pm')
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/PublicInbox/Hval.pm b/lib/PublicInbox/Hval.pm
index 0445e575..d65ad3bb 100644
--- a/lib/PublicInbox/Hval.pm
+++ b/lib/PublicInbox/Hval.pm
@@ -8,7 +8,7 @@ use warnings;
 use fields qw(raw href);
 use Encode qw(find_encoding);
 use URI::Escape qw(uri_escape_utf8);
-use PublicInbox::MID qw/mid_clean mid_compress/;
+use PublicInbox::MID qw/mid_clean/;
 my $enc_ascii = find_encoding('us-ascii');
@@ -27,7 +27,7 @@ sub new {
 sub new_msgid {
         my ($class, $msgid, $no_compress) = @_;
         $msgid = mid_clean($msgid);
-        $class->new($msgid, $no_compress ? $msgid : mid_compress($msgid));
+        $class->new($msgid, $msgid);
 sub new_oneline {