From ed79596b758935a3f22bf6803bc082a6bbe10f58 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Sat, 21 Apr 2012 23:32:33 -0400 Subject: noop --- Annex/Content.hs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'Annex/Content.hs') diff --git a/Annex/Content.hs b/Annex/Content.hs index 7022364d0..c5771af28 100644 --- a/Annex/Content.hs +++ b/Annex/Content.hs @@ -98,7 +98,7 @@ lockContent key a = do case v of Left _ -> error "content is locked" Right _ -> return $ Just fd - unlock Nothing = return () + unlock Nothing = noop unlock (Just l) = closeFd l {- Calculates the relative path to use to link a file to a key. -} @@ -237,10 +237,10 @@ cleanObjectLoc key = do file <- inRepo $ gitAnnexLocation key liftIO $ removeparents file (3 :: Int) where - removeparents _ 0 = return () + removeparents _ 0 = noop removeparents file n = do let dir = parentDir file - maybe (return ()) (const $ removeparents dir (n-1)) + maybe noop (const $ removeparents dir (n-1)) =<< catchMaybeIO (removeDirectory dir) {- Removes a key's file from .git/annex/objects/ -} -- cgit v1.2.3