# crap, Message-ID is already known, hope somebody just resent:
foreach my $m (@$mids) {
# read-only lookup now safe to do after above barrier
- my $existing = lookup_content($self, $mime, $m);
# easy, don't store duplicates
# note: do not add more diagnostic info here since
# it gets noisy on public-inbox-watch restarts
- return () if $existing;
+ return () if content_exists($self, $mime, $m);
}
# AltId may pre-populate article numbers (e.g. X-Mail-Count
$ibx->msg_by_smsg($smsg);
}
-sub lookup_content ($$$) {
+sub content_exists ($$$) {
my ($self, $mime, $mid) = @_;
my $over = $self->{over};
my $cids = content_ids($mime);
next;
}
my $cur = PublicInbox::MIME->new($msg);
- if (content_matches($cids, $cur)) {
- $smsg->{mime} = $cur;
- return $smsg;
- }
-
+ return 1 if content_matches($cids, $cur);
# XXX DEBUG_DIFF is experimental and may be removed
diff($mid, $cur, $mime) if $ENV{DEBUG_DIFF};