summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoey Hess <joey@kitenet.net>2013-11-20 16:14:12 -0400
committerJoey Hess <joey@kitenet.net>2013-11-20 16:14:12 -0400
commitd3aa5938993372daea5c38c28d2b84b9112f1fc3 (patch)
tree65656304d5b2400d1616ca2037d6ca35f58adf3f
parent8199c94bfcb2f66cacb5c6a11476485f0457d239 (diff)
downloadgit-repair-d3aa5938993372daea5c38c28d2b84b9112f1fc3.tar.gz
fix reversion of bad fsck tryharder code
-rw-r--r--Git/Fsck.hs11
1 files changed, 4 insertions, 7 deletions
diff --git a/Git/Fsck.hs b/Git/Fsck.hs
index 9c62ae0..85e6054 100644
--- a/Git/Fsck.hs
+++ b/Git/Fsck.hs
@@ -41,13 +41,10 @@ findBroken :: Bool -> Repo -> IO FsckResults
findBroken batchmode r = do
(output, fsckok) <- processTranscript command' (toCommand params') Nothing
let objs = findShas output
- if fsckok
- then do
- badobjs <- findMissing objs r
- if S.null badobjs && not fsckok
- then return Nothing
- else return $ Just badobjs
- else return Nothing
+ badobjs <- findMissing objs r
+ if S.null badobjs && not fsckok
+ then return Nothing
+ else return $ Just badobjs
where
(command, params) = ("git", fsckParams r)
(command', params')