summaryrefslogtreecommitdiff
path: root/Backend/WORM.hs
diff options
context:
space:
mode:
Diffstat (limited to 'Backend/WORM.hs')
-rw-r--r--Backend/WORM.hs10
1 files changed, 5 insertions, 5 deletions
diff --git a/Backend/WORM.hs b/Backend/WORM.hs
index 4e2177fed..e9d8c4285 100644
--- a/Backend/WORM.hs
+++ b/Backend/WORM.hs
@@ -37,11 +37,11 @@ backend = Backend.File.backend {
keyValue :: FilePath -> Annex (Maybe Key)
keyValue file = do
stat <- liftIO $ getFileStatus file
- return $ Just $ Key ((name backend), key stat)
+ return $ Just $ Key (name backend, key stat)
where
key stat = uniqueid stat ++ sep ++ base
- uniqueid stat = (show $ modificationTime stat) ++ sep ++
- (show $ fileSize stat)
+ uniqueid stat = show (modificationTime stat) ++ sep ++
+ show (fileSize stat)
base = takeFileName file
sep = ":"
@@ -58,11 +58,11 @@ checkKeySize key = do
g <- Annex.gitRepo
let file = annexLocation g key
present <- liftIO $ doesFileExist file
- if (not present)
+ if not present
then return True
else do
s <- liftIO $ getFileStatus file
- if (fileSize s == keySize key)
+ if fileSize s == keySize key
then return True
else do
dest <- moveBad key