public function CaptchaTypeFormatter::transform in CAPTCHA 8
Transforms the d7 separate captcha type and module into one row.
Overrides ProcessPluginBase::transform
File
- src/
Plugin/ migrate/ process/ CaptchaTypeFormatter.php, line 29
Class
- CaptchaTypeFormatter
- Perform captcha type transformation.
Namespace
Drupal\captcha\Plugin\migrate\processCode
public function transform($value, MigrateExecutableInterface $migrate_executable, Row $row, $destination_property) {
$module = $row
->getSourceProperty('module') ?? 'captcha';
$type = $row
->getSourceProperty('captcha_type');
return $module . '/' . $type;
}