diff --git a/app/ring_groups/ring_group_edit.php b/app/ring_groups/ring_group_edit.php index 86e950db92..60141a9f5c 100644 --- a/app/ring_groups/ring_group_edit.php +++ b/app/ring_groups/ring_group_edit.php @@ -466,11 +466,11 @@ } //add an empty row to the options array - if (count($ring_group_destinations) == 0) { + if (!is_array($ring_group_destinations) || count($ring_group_destinations) == 0) { $rows = $_SESSION['ring_group']['destination_add_rows']['numeric']; $id = 0; } - if (count($ring_group_destinations) > 0) { + if (is_array($ring_group_destinations) && count($ring_group_destinations) > 0) { $rows = $_SESSION['ring_group']['destination_edit_rows']['numeric']; $id = count($ring_group_destinations)+1; } @@ -566,20 +566,22 @@ } //show the content - echo "
"; //include the footer require_once "resources/footer.php"; -?> +?> \ No newline at end of file