diff --git a/app/ring_groups/ring_groups.php b/app/ring_groups/ring_groups.php
index 09515aa7fe..cce5fad9b9 100644
--- a/app/ring_groups/ring_groups.php
+++ b/app/ring_groups/ring_groups.php
@@ -67,7 +67,7 @@
echo "
\n";
echo " \n";
echo " | ".$text['title-ring_groups']." | \n";
-// echo " | \n";
+ //echo " | \n";
echo "
\n";
- if ($result_count > 0) {
- foreach($result as $row) {
+ if (is_array($ring_groups)) {
+ foreach($ring_groups as $row) {
$tr_link = (permission_exists('ring_group_edit')) ? "href='ring_group_edit.php?id=".$row['ring_group_uuid']."'" : null;
echo "\n";
echo " | ";
@@ -181,7 +180,7 @@
echo " |
\n";
if ($c==0) { $c=1; } else { $c=0; }
} //end foreach
- unset($sql, $result, $row_count);
+ unset($sql, $ring_groups);
} //end if results
echo "\n";
@@ -207,4 +206,5 @@
//include the footer
require_once "resources/footer.php";
+
?>