OK, the issue I experiencing is that it's possible that the MigrateDestinationNodeRevision::import() function can increment $this->numCreated twice under specific use cases.

Line :439 of plugins/destinations/node.inc increments it all the time. This also calls parent::import() which increments it if it's a new node (MigrateDestinationNode::import(), :274).

I think what needs to happen is the same as

$original_updated = $this->numUpdated;
parent::import();
$this->numUpdated = $original_updated;

Maybe:

$original_created = $this->numCreated;
parent::import();
$this->numCreated = ++$original_created;

But I don't know enough about the counts, and how they might be used further down the track.

Comments

nterbogt’s picture

Title: MigrateDestinationNodeRevision::numCreated incremented twice » MigrateDestinationNodeRevision->numCreated incremented twice
pifagor’s picture

Status: Active » Closed (outdated)