diff options
Diffstat (limited to 'Annex/Link.hs')
-rw-r--r-- | Annex/Link.hs | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/Annex/Link.hs b/Annex/Link.hs index fcc300bee..e083cfe8c 100644 --- a/Annex/Link.hs +++ b/Annex/Link.hs @@ -55,11 +55,10 @@ getAnnexLinkTarget' file coresymlinks = if coresymlinks check probefilecontent $ return Nothing where - check getlinktarget fallback = do - v <- liftIO $ catchMaybeIO $ getlinktarget file - case v of + check getlinktarget fallback = + liftIO (catchMaybeIO $ getlinktarget file) >>= \case Just l - | isLinkToAnnex (fromInternalGitPath l) -> return v + | isLinkToAnnex (fromInternalGitPath l) -> return (Just l) | otherwise -> return Nothing Nothing -> fallback |