Mercurial > hg > cmmr2012-drupal-site
comparison core/modules/migrate/src/MigrateExecutable.php @ 4:a9cd425dd02b
Update, including to Drupal core 8.6.10
author | Chris Cannam |
---|---|
date | Thu, 28 Feb 2019 13:11:55 +0000 |
parents | c75dbcec494b |
children | 12f9dff5fda9 |
comparison
equal
deleted
inserted
replaced
3:307d7a7fd348 | 4:a9cd425dd02b |
---|---|
219 } | 219 } |
220 | 220 |
221 if ($save) { | 221 if ($save) { |
222 try { | 222 try { |
223 $this->getEventDispatcher()->dispatch(MigrateEvents::PRE_ROW_SAVE, new MigratePreRowSaveEvent($this->migration, $this->message, $row)); | 223 $this->getEventDispatcher()->dispatch(MigrateEvents::PRE_ROW_SAVE, new MigratePreRowSaveEvent($this->migration, $this->message, $row)); |
224 $destination_id_values = $destination->import($row, $id_map->lookupDestinationId($this->sourceIdValues)); | 224 $destination_ids = $id_map->lookupDestinationIds($this->sourceIdValues); |
225 $destination_id_values = $destination_ids ? reset($destination_ids) : []; | |
226 $destination_id_values = $destination->import($row, $destination_id_values); | |
225 $this->getEventDispatcher()->dispatch(MigrateEvents::POST_ROW_SAVE, new MigratePostRowSaveEvent($this->migration, $this->message, $row, $destination_id_values)); | 227 $this->getEventDispatcher()->dispatch(MigrateEvents::POST_ROW_SAVE, new MigratePostRowSaveEvent($this->migration, $this->message, $row, $destination_id_values)); |
226 if ($destination_id_values) { | 228 if ($destination_id_values) { |
227 // We do not save an idMap entry for config. | 229 // We do not save an idMap entry for config. |
228 if ($destination_id_values !== TRUE) { | 230 if ($destination_id_values !== TRUE) { |
229 $id_map->saveIdMapping($row, $destination_id_values, $this->sourceRowStatus, $destination->rollbackAction()); | 231 $id_map->saveIdMapping($row, $destination_id_values, $this->sourceRowStatus, $destination->rollbackAction()); |