Skip to content
Snippets Groups Projects

Allow process plugins to stop further processing on a pipeline

Closed Michael Lutz requested to merge issue/drupal-3245997:3245997-allow-process-plugins into 11.x
All threads resolved!
Files
8
@@ -2,7 +2,6 @@
namespace Drupal\migrate\Plugin\migrate\process;
use Drupal\migrate\MigrateSkipProcessException;
use Drupal\migrate\ProcessPluginBase;
use Drupal\migrate\MigrateExecutableInterface;
use Drupal\migrate\Row;
@@ -131,7 +130,8 @@ public function row($value, MigrateExecutableInterface $migrate_executable, Row
*/
public function process($value, MigrateExecutableInterface $migrate_executable, Row $row, $destination_property) {
if (!$value) {
throw new MigrateSkipProcessException();
$this->stopPipeline();
return NULL;
}
return $value;
}
Loading