use v5.10.1;
use PublicInbox::SharedKV;
use PublicInbox::ContentHash qw(content_hash);
+use Digest::SHA ();
# n.b. mutt sets most of these headers not sure about Bytes
our @OID_IGNORE = qw(Status X-Status Content-Length Lines Bytes);
bless [ $skv, undef, undef, $m ], $cls;
}
-# returns true on unseen messages according to the deduplication strategy,
-# returns false if seen
+# returns true on seen messages according to the deduplication strategy,
+# returns false if unseen
sub is_dup {
my ($self, $eml, $oid) = @_;
!$self->[1]->($eml, $oid);
sub pause_dedupe {
my ($self) = @_;
my $skv = $self->[0];
+ $skv->dbh_release;
delete($skv->{dbh}) if $skv;
}