Skip to content

Commit

Permalink
Merge branch 'empty-container-list-block' into containerlist-block-un…
Browse files Browse the repository at this point in the history
…ittitle
  • Loading branch information
ctgraham committed Dec 17, 2021
2 parents 3d67ebc + 051a1c8 commit 6adccc9
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion includes/blocks.inc
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,10 @@ function islandora_manuscript_container_list($object) {
);
module_load_include('inc', 'islandora_manuscript', 'includes/jstreebuilder');
$builder = new \Islandora\Manuscript\ContainerListJSTreeBuilder($object);
$structure = $builder->getTreeStructure();
if (empty($structure)) {
return;
}
$form['tree']['#attached']['js'][] = array(
'type' => 'setting',
'data' => array(
Expand All @@ -58,7 +62,7 @@ function islandora_manuscript_container_list($object) {
$id => array(
'core' => array(
'multiple' => FALSE,
'data' => $builder->getTreeStructure(),
'data' => $structure,
),
'plugins' => array('types'),
'types' => array(
Expand Down

0 comments on commit 6adccc9

Please sign in to comment.