Ignore non-present packages

This commit is contained in:
Chris Done 2016-06-16 15:06:26 +02:00
parent 9c52d4b6aa
commit 8db35e2f83

View File

@ -83,7 +83,7 @@ redirectWithVersion slug rest =
Entity sid _ <- lookupSnapshot slug >>= maybe notFound return
mversion <- getPackageVersionBySnapshot sid pkg
case mversion of
Nothing -> error "That package is not part of this snapshot."
Nothing -> return Nothing -- error "That package is not part of this snapshot."
Just version -> do
return (Just (HaddockR slug [pkg <> "-" <> version, file]))
_ -> return Nothing