angular2-features icon indicating copy to clipboard operation
angular2-features copied to clipboard

DbUpdateConcurrencyException in entityframework-api

Open gitonworld opened this issue 9 years ago • 0 comments

ISSUE the entityframework-api which this repository uses to save data base changes on updating(http put) schedules throws a DbUpdateConcurrencyException when updating schedules. The data base saves, but an exception may have future side effects. Below is the fix.

MODULE- dotnetcore-entityframework-api-master\Scheduler.Data\Repositories\EntityBaseRepository.cs HANDLER- public virtual void Commit()

CHANGED FROM - context.SaveChanges(); CHANGED TO + try { _context.SaveChanges(); } catch(DbUpdateConcurrencyException ex) { // nothing for now }

gitonworld avatar Jul 22 '16 18:07 gitonworld