Open
Description
Hi, I have a little question. You have the Save method in the FoodSqlRepository class. However, this method always return positive number from 0, because the returned number is the number of state entries written to the database.
In which cases can the returned number be negative?
public class FoodSqlRepository : IFoodRepository
{
// your code
public bool Save()
{
return (_foodDbContext.SaveChanges() >= 0);
}
}
Metadata
Metadata
Assignees
Labels
No labels