about summary refs log tree commit homepage
path: root/lib/PublicInbox/Import.pm
diff options
context:
space:
mode:
authorEric Wong <e@80x24.org>2021-10-16 01:00:52 +0000
committerEric Wong <e@80x24.org>2021-10-16 01:42:47 +0000
commit879547527204b878b80804c2f19c6ef71458194e (patch)
tree82db8884c66d6d86983dc7721e59b4db33fcb17a /lib/PublicInbox/Import.pm
parent299b40d252cf4d4db6fa29ad18cb78777f1f55fc (diff)
downloadpublic-inbox-879547527204b878b80804c2f19c6ef71458194e.tar.gz
smsg: add ->oidbin method
This makes some of our code less noisy by reducing the
amount of pack('H*', ...) use.
Diffstat (limited to 'lib/PublicInbox/Import.pm')
-rw-r--r--lib/PublicInbox/Import.pm2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/PublicInbox/Import.pm b/lib/PublicInbox/Import.pm
index 17adfabd..60ce7b66 100644
--- a/lib/PublicInbox/Import.pm
+++ b/lib/PublicInbox/Import.pm
@@ -423,7 +423,7 @@ sub add {
                                 $x->dbh;
                                 $x;
                         };
-                        return if !$u->set_maybe(pack('H*', $smsg->{blob}), 1);
+                        return if !$u->set_maybe($smsg->oidbin, 1);
                         return if (!$oidx->vivify_xvmd($smsg) &&
                                         $eidx_git->check($smsg->{blob}));
                 }