diff --git a/core/modules/file/src/Plugin/migrate/source/d7/File.php b/core/modules/file/src/Plugin/migrate/source/d7/File.php index 0fcb9e3..0c1b00d 100644 --- a/core/modules/file/src/Plugin/migrate/source/d7/File.php +++ b/core/modules/file/src/Plugin/migrate/source/d7/File.php @@ -91,7 +91,9 @@ public function prepareRow(Row $row) { // the source_base_path in order to make them all relative. // @todo Don't depend on destination configuration. // @see https://www.drupal.org/node/2577871 - $path = str_replace($this->migration->get('destination')['source_base_path'], NULL, $path); + + // @TODO, figure out why this is done here and not the destination. + // $path = str_replace($this->migration->get('destination')['source_base_path'], NULL, $path); $row->setSourceProperty('filepath', $path); return parent::prepareRow($row); } diff --git a/core/modules/migrate_drupal/src/MigrationCreationTrait.php b/core/modules/migrate_drupal/src/MigrationCreationTrait.php index 99420a8..2c2ad4f 100644 --- a/core/modules/migrate_drupal/src/MigrationCreationTrait.php +++ b/core/modules/migrate_drupal/src/MigrationCreationTrait.php @@ -126,24 +126,14 @@ protected function getMigrations($database_state_key, $drupal_version, $source_b } try { - // Any plugin that has specific requirements to check will implement - // RequirementsInterface. - $source_plugin = $migration->getSourcePlugin(); - if ($source_plugin instanceof RequirementsInterface) { - $source_plugin->checkRequirements(); - } - $destination_plugin = $migration->getDestinationPlugin(); - if ($destination_plugin instanceof RequirementsInterface) { - $destination_plugin->checkRequirements(); - } + // Ensure all the requirements for the migration have been met. + $migration->checkRequirements(); $migrations[] = $migration; } + catch (RequirementsException $e) { // Migrations which are not applicable given the source and destination // site configurations (e.g., what modules are enabled) will be silently // ignored. - catch (RequirementsException $e) { - } - catch (PluginNotFoundException $e) { } }