From cc13dd82c5cd7647f911ed6be1e58694f7edee31 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Fri, 12 Feb 2016 16:48:03 -0400 Subject: avoid --batch crashing if a remote fails to be accessed --- Command/CheckPresentKey.hs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'Command') diff --git a/Command/CheckPresentKey.hs b/Command/CheckPresentKey.hs index 6fe1f552c..29df810a6 100644 --- a/Command/CheckPresentKey.hs +++ b/Command/CheckPresentKey.hs @@ -68,8 +68,7 @@ exitResult (CheckFailure msg) = liftIO $ do batchResult :: Result -> Annex () batchResult Present = liftIO $ putStrLn "1" -batchResult NotPresent = liftIO $ putStrLn "0" -batchResult failure = exitResult failure +batchResult _ = liftIO $ putStrLn "0" toKey :: String -> Key toKey = fromMaybe (error "Bad key") . file2key -- cgit v1.2.3