serveChangeLog' :: (DynamicPath -> ((PkgInfo -> ServerPartE Response) -> ServerPartE Response))
                -> BlobStorage -> DynamicPath -> ServerPart Response
serveChangeLog' with_pkg_path store dpath = runServerPartE $ with_pkg_path dpath $ \pkg -> do
    res <- liftIO $ lookupChangeLog store pkg
    case res of
      Left err -> errNotFound "Changelog not found" [MText err]
      Right (fp, offset, name) -> liftIO $ TarIndex.serveTarEntry fp offset name

-- return: not-found error or tarball
serveChangeLog' :: (DynamicPath -> ((PkgInfo -> ServerPartE Response) -> ServerPartE Response))
                -> BlobStorage -> DynamicPath -> ServerPart Response
serveChangeLog' with_pkg_path store dpath = runServerPartE $ with_pkg_path dpath $ \pkg -> do
    res <- liftIO $ lookupChangeLog store pkg
    case res of
      Left err -> errNotFound "Changelog not found" [MText err]
      Right (fp, offset, name) -> liftIO $ TarIndex.serveTarEntry fp offset name

-- return: not-found error or tarball
serveChangeLog' with_pkg_path store dpath = runServerPartE $ with_pkg_path dpath $ \pkg -> do
    res <- liftIO $ lookupChangeLog store pkg
    case res of
      Left err -> errNotFound "Changelog not found" [MText err]
      Right (fp, offset, name) -> liftIO $ TarIndex.serveTarEntry fp offset name

-- return: not-found error or tarball