This project is read-only.

Clear _queuedRecords

Feb 2, 2010 at 2:58 PM

Hello,

I noticed that I was getting duplicate entries sometimes.  It appears that this was occuring because I was using the same data context to update multiple records.  In other words, I'd pass in one Entity, call SubmitChanges, and then pass in another entity and call SubmitChanges again.  I noticed that "_queuedRecords" was still populated with the first entity when SubmitChanges was called the second time.  In order to resolve this I added the following statement to the end of AuditableDataContext.SubmitChanges():

_queuedRecords.Clear();

This appears to have cleared up the issue.    Should I expect to encounter any problems as a result of this change?  If not, do you think this change should be added to the latest version of DoddleAudit?

Thanks,

Seth

Feb 10, 2010 at 3:39 AM

Known issue, see work item 2321.  Also watch out for 2398 :)