Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
... is not working. I think it is because there is a bug in the callback function.
I've changed it to this.
function feeds_tamper_truncate_text_callback($result, $item_key, $element_key, &$field, $settings, $source) {
if (!is_array($field)) {
$field = array($field);
}
$out = array();
foreach ($field as $f) {
$out[] = truncate_utf8($f, $settings['num_char'], FALSE, $settings['ellipses']);
}
$field = $out;
// $field = truncate_utf8($field, $settings['num_char'], FALSE, $settings['ellipses']);
}
Maybe it is helpful.
Comments
Comment #1
illeace CreditAttribution: illeace commentedI believe the root issue is the one I've written up in #2119745: Fields converted to arrays during import are not processed as arrays by subsequent plugins.
Comment #2
twistor CreditAttribution: twistor commentedYup
#2119745: Fields converted to arrays during import are not processed as arrays by subsequent plugins