]> Sergey Matveev's repositories - public-inbox.git/commitdiff
thread: limit scope of monkey patch
authorEric Wong <e@80x24.org>
Thu, 1 May 2014 18:33:18 +0000 (18:33 +0000)
committerEric Wong <e@80x24.org>
Thu, 1 May 2014 18:33:18 +0000 (18:33 +0000)
Future versions of Mail::Thread may be released to fix this bug.
However, since it's been about 8 years since the bug was reported..

lib/PublicInbox/Thread.pm

index a2553da70ab4bab16d5bceaf927ec436a84840e5..7dabf2439927ee2a6546b3218d060b109a999dc4 100644 (file)
@@ -7,7 +7,10 @@ package PublicInbox::Thread;
 use strict;
 use warnings;
 use base qw(Mail::Thread);
-sub _container_class { 'PublicInbox::Thread::Container' }
+
+if ($Mail::Thread::VERSION <= 2.55) {
+       eval q(sub _container_class { 'PublicInbox::Thread::Container' });
+}
 
 package PublicInbox::Thread::Container;
 use strict;