From 82161654830b0dc4187e9928555c9321ef61bb89 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Wed, 28 Jan 2015 16:11:28 -0400 Subject: import Data.Default in Common --- Annex/FileMatcher.hs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'Annex/FileMatcher.hs') diff --git a/Annex/FileMatcher.hs b/Annex/FileMatcher.hs index c6a729a9c..16ade922c 100644 --- a/Annex/FileMatcher.hs +++ b/Annex/FileMatcher.hs @@ -28,12 +28,12 @@ checkFileMatcher :: (FileMatcher Annex) -> FilePath -> Annex Bool checkFileMatcher matcher file = checkMatcher matcher Nothing (Just file) S.empty True checkMatcher :: (FileMatcher Annex) -> Maybe Key -> AssociatedFile -> AssumeNotPresent -> Bool -> Annex Bool -checkMatcher matcher mkey afile notpresent def - | isEmpty matcher = return def +checkMatcher matcher mkey afile notpresent d + | isEmpty matcher = return d | otherwise = case (mkey, afile) of (_, Just file) -> go =<< fileMatchInfo file (Just key, _) -> go (MatchingKey key) - _ -> return def + _ -> return d where go mi = matchMrun matcher $ \a -> a notpresent mi -- cgit v1.2.3