diff --git a/internal/internal.go b/internal/internal.go index a21a2fc..288b1df 100644 --- a/internal/internal.go +++ b/internal/internal.go @@ -134,6 +134,9 @@ func GenerateChangeSet(logger *log.Logger, sourcePeople, destinationPeople []Per if !personAttributesAreEqual(logger, sp, destinationPerson, config) { sp.ID = destinationPerson.Attributes["id"] + if destinationPerson.ID != "" { // use ID if it is set to something else + sp.ID = destinationPerson.ID + } changeSet.Update = append(changeSet.Update, sp) continue }