I’m trying to migrate some data from a remote rest/api (json) using the plugin source url. My problem is in the json i consume the image name field comes with an incorrect value.
In imageName
comes '0_3.jpg' and the correct name is '0_3.png', for example
So i have the following code trying to transform the name:
source_full_path:
-
plugin: concat
delimiter: /
source:
- constants/source_base_path
- imageName:
plugin: str_replace
source: imageName
search: "jpg"
replace: "png"
but this gives the following error:
TypeError: Argument 2 passed to Drupal\Component\Utility\NestedArray::getValue() must be of the type array, null given
Anyone has any idea?