diff options
author | Joey Hess <joey@kitenet.net> | 2014-08-08 14:19:08 -0400 |
---|---|---|
committer | Joey Hess <joey@kitenet.net> | 2014-08-08 14:19:08 -0400 |
commit | 49f5a1be8bc8b6aee6d65d61d316571317b79174 (patch) | |
tree | 0f0955b390e576f425eaab14e2ce192d3437b02b /Remote | |
parent | e90f4c9b7c15c7a86b099e2f76d02237b78054e7 (diff) |
show missing url= parameter error sooner
Diffstat (limited to 'Remote')
-rw-r--r-- | Remote/WebDAV.hs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/Remote/WebDAV.hs b/Remote/WebDAV.hs index 2c621b633..af3af7902 100644 --- a/Remote/WebDAV.hs +++ b/Remote/WebDAV.hs @@ -77,8 +77,9 @@ gen r u c gc = new <$> remoteCost gc expensiveRemoteCost webdavSetup :: Maybe UUID -> Maybe CredPair -> RemoteConfig -> Annex (RemoteConfig, UUID) webdavSetup mu mcreds c = do u <- maybe (liftIO genUUID) return mu - let url = fromMaybe (error "Specify url=") $ - M.lookup "url" c + url <- case M.lookup "url" c of + Nothing -> error "Specify url=" + Just url -> return url c' <- encryptionSetup c creds <- maybe (getCreds c' u) (return . Just) mcreds testDav url creds |