public String deleteNewsItem(int newsItemId) { return(newsRepository.DeleteNewsItem(newsItemId)); }
public void DeleteNewsById(int id) { //var entity = _newsRepository.GetNewsById(id); //if (entity == null) { throw new Exception($"NewsItem with id {id} was not found."); } _newsRepository.DeleteNewsItem(id); }