function NodeTranslationMigrateSubscriber::isNodeTranslationsMigration
Helper method to check if we are migrating translated nodes.
Parameters
\Drupal\migrate\Event\EventBase $event: The migrate event.
Return value
bool True if we are migrating translated nodes, false otherwise.
2 calls to NodeTranslationMigrateSubscriber::isNodeTranslationsMigration()
- NodeTranslationMigrateSubscriber::onPostImport in core/modules/ node/ src/ EventSubscriber/ NodeTranslationMigrateSubscriber.php 
- Set the node_translation_redirect state to enable the redirects.
- NodeTranslationMigrateSubscriber::onPostRowSave in core/modules/ node/ src/ EventSubscriber/ NodeTranslationMigrateSubscriber.php 
- Maps the old nid to the new one in the key value collection.
File
- 
              core/modules/ node/ src/ EventSubscriber/ NodeTranslationMigrateSubscriber.php, line 66 
Class
- NodeTranslationMigrateSubscriber
- Creates a key value collection for migrated node translation mappings.
Namespace
Drupal\node\EventSubscriberCode
protected function isNodeTranslationsMigration(EventBase $event) {
  $migration = $event->getMigration();
  $source_configuration = $migration->getSourceConfiguration();
  $destination_configuration = $migration->getDestinationConfiguration();
  return !empty($source_configuration['translations']) && $destination_configuration['plugin'] === 'entity:node';
}Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.
