public ActionResult DeleteRecipe(int id) { var recipeEntity = _homeBrewRepository.GetRecipe(id, false); if (recipeEntity == null) { return(NotFound()); } _homeBrewRepository.DeleteRecipe(recipeEntity); _homeBrewRepository.Save(); return(NoContent()); }