From 49f5a1be8bc8b6aee6d65d61d316571317b79174 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Fri, 8 Aug 2014 14:19:08 -0400 Subject: show missing url= parameter error sooner --- Remote/WebDAV.hs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'Remote') 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 -- cgit v1.2.3