hlint
This commit is contained in:
parent
f25991ca33
commit
3ac9c4e672
11 changed files with 52 additions and 54 deletions
|
@ -85,13 +85,13 @@ failedTransferScan r = do
|
|||
mapM_ retry failed
|
||||
where
|
||||
retry (t, info)
|
||||
| transferDirection t == Download = do
|
||||
| transferDirection t == Download =
|
||||
{- Check if the remote still has the key.
|
||||
- If not, relies on the expensiveScan to
|
||||
- get it queued from some other remote. -}
|
||||
whenM (liftAnnex $ remoteHas r $ transferKey t) $
|
||||
requeue t info
|
||||
| otherwise = do
|
||||
| otherwise =
|
||||
{- The Transferrer checks when uploading
|
||||
- that the remote doesn't already have the
|
||||
- key, so it's not redundantly checked here. -}
|
||||
|
@ -161,7 +161,7 @@ expensiveScan urlrenderer rs = unless onlyweb $ batch <~> do
|
|||
present key (Just f) Nothing
|
||||
liftAnnex $ do
|
||||
let slocs = S.fromList locs
|
||||
let use a = return $ catMaybes $ map (a key slocs) syncrs
|
||||
let use a = return $ mapMaybe (a key slocs) syncrs
|
||||
ts <- if present
|
||||
then filterM (wantSend True (Just f) . Remote.uuid . fst)
|
||||
=<< use (genTransfer Upload False)
|
||||
|
@ -173,7 +173,7 @@ expensiveScan urlrenderer rs = unless onlyweb $ batch <~> do
|
|||
genTransfer :: Direction -> Bool -> Key -> S.Set UUID -> Remote -> Maybe (Remote, Transfer)
|
||||
genTransfer direction want key slocs r
|
||||
| direction == Upload && Remote.readonly r = Nothing
|
||||
| (S.member (Remote.uuid r) slocs) == want = Just
|
||||
| S.member (Remote.uuid r) slocs == want = Just
|
||||
(r, Transfer direction (Remote.uuid r) key)
|
||||
| otherwise = Nothing
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue