private async Task <List <DataBlockViewModel> > GetDataBlocksWithHighlights(Release release) { return((await _dataBlockService.List(release.Id)) .FoldRight( dataBlocks => dataBlocks .Where(dataBlock => !dataBlock.HighlightName.IsNullOrEmpty()) .ToList(), new List <DataBlockViewModel>() )); }
public async Task <ActionResult <List <DataBlockViewModel> > > GetDataBlocks(Guid releaseId) { return(await _dataBlockService.List(releaseId) .HandleFailuresOrOk()); }