show missing url= parameter error sooner
This commit is contained in:
		
					parent
					
						
							
								ec11e0b89a
							
						
					
				
			
			
				commit
				
					
						6cb9e5c32f
					
				
			
		
					 1 changed files with 3 additions and 2 deletions
				
			
		| 
						 | 
					@ -77,8 +77,9 @@ gen r u c gc = new <$> remoteCost gc expensiveRemoteCost
 | 
				
			||||||
webdavSetup :: Maybe UUID -> Maybe CredPair -> RemoteConfig -> Annex (RemoteConfig, UUID)
 | 
					webdavSetup :: Maybe UUID -> Maybe CredPair -> RemoteConfig -> Annex (RemoteConfig, UUID)
 | 
				
			||||||
webdavSetup mu mcreds c = do
 | 
					webdavSetup mu mcreds c = do
 | 
				
			||||||
	u <- maybe (liftIO genUUID) return mu
 | 
						u <- maybe (liftIO genUUID) return mu
 | 
				
			||||||
	let url = fromMaybe (error "Specify url=") $
 | 
						url <- case M.lookup "url" c of
 | 
				
			||||||
		M.lookup "url" c
 | 
							Nothing -> error "Specify url="
 | 
				
			||||||
 | 
							Just url -> return url
 | 
				
			||||||
	c' <- encryptionSetup c
 | 
						c' <- encryptionSetup c
 | 
				
			||||||
	creds <- maybe (getCreds c' u) (return . Just) mcreds
 | 
						creds <- maybe (getCreds c' u) (return . Just) mcreds
 | 
				
			||||||
	testDav url creds
 | 
						testDav url creds
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue