NullCoalesce wasn't working on the migration of field_image/0/alt value, until I further realised it was giving an empty string in its' value from db table.
Provide Empty string value coalesce processing as an alternative compared to NullCoalesce.
Even though we could create a NULL value by additional processing of empty string validation, it would be an extra hassle for general migrations. Especially to people who has no visual of the migration values.
Example:
Value shows empty string imported
process:
title:
-
plugin: get
source: title
field_image/0/alt:
-
plugin: null_coalesce
source:
- field_image/0/alt
- title
The field_image/0/alt
shows an empty string instead of NULL value, therefore not returning source title
Add a new process plugin that is similar to NullCoalesce, but returns "empty string" in the end when all source value loops through !empty.
foreach ($value as $val) {
if (!empty($val)) {
return $val;
}
}
return "";
Closed: won't fix
5.0
Plugins
Not all content is available!
It's likely this issue predates Contrib.social: some issue and comment data are missing.