summaryrefslogtreecommitdiff
path: root/Command/RecvKey.hs
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2013-03-30 19:05:51 -0400
committerGravatar Joey Hess <joey@kitenet.net>2013-03-30 19:05:51 -0400
commit7ad60a109ab957499a45ac93697a86a5633bf96d (patch)
tree72eedfec2cef09b5ede9bbc8db4e0c566cd5e3c3 /Command/RecvKey.hs
parent883395c399a0996d825711c6d8f29aa49ed07a69 (diff)
minor refactoring
Diffstat (limited to 'Command/RecvKey.hs')
-rw-r--r--Command/RecvKey.hs6
1 files changed, 2 insertions, 4 deletions
diff --git a/Command/RecvKey.hs b/Command/RecvKey.hs
index a1c6093e8..041e104a7 100644
--- a/Command/RecvKey.hs
+++ b/Command/RecvKey.hs
@@ -20,8 +20,6 @@ import qualified Types.Key
import qualified Types.Backend
import qualified Backend
-import System.Console.GetOpt
-
def :: [Command]
def = [noCommit $ command "recvkey" paramKey seek
SectionPlumbing "runs rsync in server mode to receive content"]
@@ -44,8 +42,8 @@ start key = ifM (inAnnex key)
)
where
go tmp = do
- (opts,_,_) <- getOpt Permute rsyncSafeOptions <$>
- maybe [] words <$> getField "RsyncOptions"
+ opts <- filterRsyncSafeOptions . maybe [] words
+ <$> getField "RsyncOptions"
ifM (liftIO $ rsyncServerReceive (map Param opts) tmp)
( ifM (isJust <$> Fields.getField Fields.direct)
( directcheck tmp