summaryrefslogtreecommitdiff
path: root/Command/Fsck.hs
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2012-01-19 13:51:30 -0400
committerGravatar Joey Hess <joey@kitenet.net>2012-01-19 13:51:30 -0400
commitd36525e9745b90cc04abfeac6500ff646cb9c89b (patch)
treeb497b310b7e9da8e00859a9eed616b36c297c07b /Command/Fsck.hs
parent50c063df069682bdac2af3b1746933da70a519b8 (diff)
convert fsckKey to a Maybe
This way it's clear when a backend does not implement its own fsck checks.
Diffstat (limited to 'Command/Fsck.hs')
-rw-r--r--Command/Fsck.hs4
1 files changed, 3 insertions, 1 deletions
diff --git a/Command/Fsck.hs b/Command/Fsck.hs
index 680828748..051a58fb4 100644
--- a/Command/Fsck.hs
+++ b/Command/Fsck.hs
@@ -137,7 +137,9 @@ checkKeySize key = do
checkBackend :: Backend -> Key -> Annex Bool
-checkBackend = Types.Backend.fsckKey
+checkBackend backend key = case Types.Backend.fsckKey backend of
+ Nothing -> return True
+ Just a -> a key
checkKeyNumCopies :: Key -> FilePath -> Maybe Int -> Annex Bool
checkKeyNumCopies key file numcopies = do