From 7afb1f428ac620253b55969df4f533fbf18b80a1 Mon Sep 17 00:00:00 2001 From: Axel Rutz Date: Mon, 7 Sep 2015 16:37:58 +0200 Subject: [PATCH] Interdiff --- token.module | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/token.module b/token.module index 74cb78f..9288bd6 100644 --- a/token.module +++ b/token.module @@ -390,7 +390,8 @@ function token_preprocess_field_multiple_value_form(&$variables) { } // Unsupported field type. else { - unset($element); // Clear ref. + // Clear ref. + unset($element); return; } @@ -405,21 +406,23 @@ function token_preprocess_field_multiple_value_form(&$variables) { // field collection). if ($bundle == $field_name) { // Our options exhausted - field type + cardinality not supported. - unset($element); // Clear ref. + // Clear ref. + unset($element); return; } } $instance_info = field_info_instance($entity_type, $field_name, $bundle); if ($instance_info && !empty($instance_info['description'])) { + // There's another description in $variables['element'][0]['#description'] + // but that normally doesn't get rendered. $element['#description'] = field_filter_xss(token_replace($instance_info['description'])); } } - unset($element); // Clear ref. + // Clear ref. + unset($element); } } - // There's another description in $variables['element'][0]['#description'] - // but that normally doesn't get rendered. } /** -- 2.1.4