//D-Delete Categories public void deleteCategory(Category category) { this.Categories.Remove(category); this.SaveChanges(); }
//I put the CRUD in here, and identified it below. This way, I was able to save the changes in a cleaner way //then I did in the previous Blog/Post. I repeated it in the Switch on Blog/Post. This time I tried to clean //up my code so I didn't do that //C-Create Categories public void addCategory(Category category) { this.Categories.Add(category); this.SaveChanges(); }