removed all uses of undefined from code base
It's a code smell, can lead to hard to diagnose error messages.
This commit is contained in:
parent
d7f4c823d7
commit
addc82dab7
19 changed files with 42 additions and 37 deletions
|
@ -143,10 +143,10 @@ firstRun :: Maybe HostName -> IO ()
|
|||
firstRun listenhost = do
|
||||
checkEnvironmentIO
|
||||
{- Without a repository, we cannot have an Annex monad, so cannot
|
||||
- get a ThreadState. Using undefined is only safe because the
|
||||
- get a ThreadState. This is only safe because the
|
||||
- webapp checks its noAnnex field before accessing the
|
||||
- threadstate. -}
|
||||
let st = undefined
|
||||
let st = error "annex state not available"
|
||||
{- Get a DaemonStatus without running in the Annex monad. -}
|
||||
dstatus <- atomically . newTMVar =<< newDaemonStatus
|
||||
d <- newAssistantData st dstatus
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue