I'm used to Entity Framework 6 and my base repository Save() looks like this:
public void Save()
{
try
{
Context.SaveChanges();
}
catch (DbEntityValidationException ex)
{
// Do stuff
}
catch (Exception exception)
{
// Do stuff
}
else
{
throw;
}
}
DbEntityValidationException is an expected error from Entity Framework if the object save is invalid. Now that I'm on a new .NET Core 2 project. What is the expected entity validation error type in Entity Framework Core?