aboutsummaryrefslogtreecommitdiff
path: root/src/libstore/daemon.cc
diff options
context:
space:
mode:
authorEelco Dolstra <edolstra@gmail.com>2018-09-25 18:55:37 +0200
committerEelco Dolstra <edolstra@gmail.com>2019-10-29 13:38:24 +0100
commit992a2ad4757f43c02f3d06771c632a408d90ded0 (patch)
treee1c19063bab26372f1b626c404a4d9c960ae21ef /src/libstore/daemon.cc
parent05819d013fb39eb9902d952978fff7f69e0e326e (diff)
Move addToStoreFromDump to Store
Diffstat (limited to 'src/libstore/daemon.cc')
-rw-r--r--src/libstore/daemon.cc5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/libstore/daemon.cc b/src/libstore/daemon.cc
index cc1436f90..64147027b 100644
--- a/src/libstore/daemon.cc
+++ b/src/libstore/daemon.cc
@@ -316,10 +316,7 @@ static void performOp(TunnelLogger * logger, ref<Store> store,
logger->startWork();
if (!savedRegular.regular) throw Error("regular file expected");
- auto store2 = store.dynamic_pointer_cast<LocalStore>();
- if (!store2) throw Error("operation is only supported by LocalStore");
-
- Path path = store2->addToStoreFromDump(recursive ? *savedNAR.data : savedRegular.s, baseName, recursive, hashAlgo);
+ Path path = store->addToStoreFromDump(recursive ? *savedNAR.data : savedRegular.s, baseName, recursive, hashAlgo);
logger->stopWork();
to << path;