public async Task <ActionResult <List <Meal> > > GetMeals() { try { var meals = await _mealDataModel.FindAllAsync().ConfigureAwait(true); return(Ok(meals)); } catch (Exception ex) { _logger.LogError(ex, GetType().Name); throw; } }
public async Task <ICollection <Meal> > FindAllAsync() { return(await _mealDataModel.FindAllAsync().ConfigureAwait(false)); }