summaryrefslogtreecommitdiff
path: root/Assistant
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2012-09-24 13:16:08 -0400
committerGravatar Joey Hess <joey@kitenet.net>2012-09-24 13:16:08 -0400
commit364b40e5fcad5e6221df75b49953c838407a4546 (patch)
tree35d33778efd112e88ade0a57b4ca3cd34c252880 /Assistant
parentd77ff5daddfd9ef73dd04ceda57dfc188054e72e (diff)
don't queue uploads for failed downloads
Diffstat (limited to 'Assistant')
-rw-r--r--Assistant/Threads/TransferWatcher.hs15
1 files changed, 8 insertions, 7 deletions
diff --git a/Assistant/Threads/TransferWatcher.hs b/Assistant/Threads/TransferWatcher.hs
index d4ff9176e..33f0dacbe 100644
--- a/Assistant/Threads/TransferWatcher.hs
+++ b/Assistant/Threads/TransferWatcher.hs
@@ -11,6 +11,7 @@ import Assistant.Common
import Assistant.ThreadedMonad
import Assistant.DaemonStatus
import Assistant.TransferQueue
+import Annex.Content
import Logs.Transfer
import Utility.DirWatcher
import Utility.Types.DirWatcher
@@ -106,11 +107,11 @@ onDel st dstatus transferqueue file _ = case parseTransferFile file of
- spreading them out to other reachable remotes. -}
case (minfo, transferDirection t) of
(Just info, Download) -> runThreadState st $
- queueTransfersMatching
- (/= transferUUID t)
- Later transferqueue dstatus
- (transferKey t)
- (associatedFile info)
- Upload
+ whenM (inAnnex $ transferKey t) $
+ queueTransfersMatching
+ (/= transferUUID t)
+ Later transferqueue dstatus
+ (transferKey t)
+ (associatedFile info)
+ Upload
_ -> noop
-