about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--src/libstore/store-api.cc6
1 files changed, 1 insertions, 5 deletions
diff --git a/src/libstore/store-api.cc b/src/libstore/store-api.cc
index 7a8a3f7dee04..fa6ade75002a 100644
--- a/src/libstore/store-api.cc
+++ b/src/libstore/store-api.cc
@@ -593,23 +593,19 @@ void copyStorePath(ref<Store> srcStore, ref<Store> dstStore,
     MyStringSink sink(progress);
     srcStore->narFromPath({storePath}, sink);
 
-    if (!info->narHash && !checkSigs) {
+    if (!info->narHash) {
         auto info2 = make_ref<ValidPathInfo>(*info);
         info2->narHash = hashString(htSHA256, *sink.s);
         if (!info->narSize) info2->narSize = sink.s->size();
         info = info2;
     }
 
-    assert(info->narHash);
-
     if (info->ultimate) {
         auto info2 = make_ref<ValidPathInfo>(*info);
         info2->ultimate = false;
         info = info2;
     }
 
-    assert(info->narHash);
-
     dstStore->addToStore(*info, sink.s, repair, checkSigs);
 }