public bool SaveChanges() { bool returnValue = true; using (var dbContextTransaction = _context.Database.BeginTransaction()) { try { _context.SaveChanges(); dbContextTransaction.Commit(); } catch (Exception ex) { //Log Exception Handling message returnValue = false; // ex.ToString(); //_logger.LogException(nameof(SaveChanges), ex, "There was an error on '{0}' invocation", nameof(SaveChanges)); dbContextTransaction.Rollback(); //throw ex; } } return(returnValue); }