diff --git a/src/WorkItemMigrator/WorkItemImport/Agent.cs b/src/WorkItemMigrator/WorkItemImport/Agent.cs index b932190..c336e28 100644 --- a/src/WorkItemMigrator/WorkItemImport/Agent.cs +++ b/src/WorkItemMigrator/WorkItemImport/Agent.cs @@ -662,6 +662,8 @@ private bool ApplyAndSaveLinks(WiRevision rev, WorkItem wi, Settings settings) // If this revision already has any fields, defer the link import by 2 miliseconds. Otherwise the Work Items API will // send the response: "VS402625: Dates must be increasing with each revision" saveLinkTimestamp = saveLinkTimestamp.AddMilliseconds(2); + // This needs to be set so that ApplyFields gets a later date, later on in the revision import + wi.Fields[WiFieldReference.ChangedDate] = saveLinkTimestamp.AddMilliseconds(2); } for (int i = 0; i < rev.Links.Count; i++) @@ -690,6 +692,8 @@ private bool ApplyAndSaveLinks(WiRevision rev, WorkItem wi, Settings settings) // If this has multiple link updates, defer each ubsequent link import by 2 miliseconds. // Otherwise the Work Items API will send the response: "VS402625: Dates must be increasing with each revision" saveLinkTimestamp = saveLinkTimestamp.AddMilliseconds(2); + // This needs to be set so that ApplyFields gets a later date, later on in the revision import + wi.Fields[WiFieldReference.ChangedDate] = saveLinkTimestamp.AddMilliseconds(2); } if (link.Change == ReferenceChangeType.Added && !_witClientUtils.AddAndSaveLink(link, wi, settings, rev.Author, saveLinkTimestamp))