initial try at using storeExportWithContentIdentifier

Untested, and I'm not sure about the locking of the ContentIdentifier db.
This commit is contained in:
Joey Hess 2019-03-04 17:50:41 -04:00
parent b67fa2180e
commit cd3a2b023a
No known key found for this signature in database
GPG key ID: DB12DB0FF05F8F38
6 changed files with 96 additions and 56 deletions

View file

@ -163,9 +163,9 @@ getExportedLocation (ExportHandle h _) k = H.queryDbQueue h $ do
- Note that this does not see recently queued changes.
-}
getExportedKey :: ExportHandle -> ExportLocation -> IO [Key]
getExportedKey ExportHandle h _) el = H.queryDbQueue h $ do
getExportedKey (ExportHandle h _) el = H.queryDbQueue h $ do
l <- selectList [ExportedFile ==. ef] []
return $ map (fromSKey . exportedKey . entityVal) l
return $ map (fromIKey . exportedKey . entityVal) l
where
ef = toSFilePath (fromExportLocation el)