Created
February 16, 2023 08:41
-
-
Save efpapado/d049393a6edead10b359681bcea10b86 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/src/MigrateBatchExecutable.php b/src/MigrateBatchExecutable.php | |
index 8e94e6e..6de934e 100644 | |
--- a/src/MigrateBatchExecutable.php | |
+++ b/src/MigrateBatchExecutable.php | |
@@ -44,6 +44,13 @@ class MigrateBatchExecutable extends MigrateExecutable { | |
*/ | |
protected $migrationPluginManager; | |
+ /** | |
+ * An array of configuration relevant to the plugin instance. | |
+ * | |
+ * @var array | |
+ */ | |
+ protected $migrationPluginConfiguration = []; | |
+ | |
/** | |
* {@inheritdoc} | |
*/ | |
@@ -59,6 +66,10 @@ class MigrateBatchExecutable extends MigrateExecutable { | |
parent::__construct($migration, $message, $options); | |
$this->migrationPluginManager = \Drupal::getContainer()->get('plugin.manager.migration'); | |
+ | |
+ if (isset($options['configuration'])) { | |
+ $this->migrationPluginConfiguration = $options['configuration']; | |
+ } | |
} | |
/** | |
@@ -92,6 +103,7 @@ class MigrateBatchExecutable extends MigrateExecutable { | |
'limit' => $this->itemLimit, | |
'update' => $this->updateExistingRows, | |
'force' => $this->checkDependencies, | |
+ 'configuration' => $this->migrationPluginConfiguration, | |
]); | |
if (count($operations) > 0) { | |
@@ -141,6 +153,7 @@ class MigrateBatchExecutable extends MigrateExecutable { | |
'limit' => 0, | |
'update' => $options['update'], | |
'force' => $options['force'], | |
+ 'configuration' => $options['configuration'], | |
])); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment