Browse Source

Changed based on code review to pull #657

Its possible that $variables['dc_array'] is an empty array which would
generate a warning. Just cleaning up this possible case.
pull/658/head
Jonathan Green 8 years ago
parent
commit
f0ac57a8ba
  1. 2
      theme/theme.inc

2
theme/theme.inc

@ -646,8 +646,10 @@ function islandora_preprocess_islandora_dublin_core_description(array &$variable
}
}
$variables['dc_array'] = isset($dc_object) ? $dc_object->asArray() : array();
if (isset($variables['dc_array']['dc:description']['value'])) {
$variables['dc_array']['dc:description']['value'] = nl2br(filter_xss($variables['dc_array']['dc:description']['value']));
}
}
/**
* Implements hook_preprocess().

Loading…
Cancel
Save