Checks if return is empty before adding wrapper classes to tainacan relationship group in value as html.

This commit is contained in:
mateuswetah 2021-09-23 14:54:10 -03:00
parent fae9e45b91
commit 957430320a
1 changed files with 1 additions and 1 deletions

View File

@ -217,7 +217,7 @@ class Relationship extends Metadata_Type {
// item not found
}
}
if(!empty($display_metas) && is_array($display_metas) && count($display_metas) > 1) {
if(!empty($display_metas) && is_array($display_metas) && count($display_metas) > 1 && $return !== '') {
return "<div class='tainacan-relationship-group'>{$return}</div>";
}
return $return;