]> git.mjollnir.org Git - moodle.git/commitdiff
fix for #5173
authortoyomoyo <toyomoyo>
Thu, 13 Apr 2006 01:32:10 +0000 (01:32 +0000)
committertoyomoyo <toyomoyo>
Thu, 13 Apr 2006 01:32:10 +0000 (01:32 +0000)
blog/tags.html

index 611758c11541a3cb540e9479a6189400bc8f58fe..c664b83577073b25b966f098a511eabf32a98c77 100755 (executable)
@@ -26,9 +26,10 @@ print_heading(get_string('tagmanagement'));
             <input type="submit" value="<?php print_string('delete');?>" />
             <?php }
                 else {
-                    $otags = get_records_sql('SELECT * from '.$CFG->prefix.'tags WHERE type=\'official\' ORDER by text ASC');
-                    foreach ($otags as $otag) {
-                        echo '<br />'.$otag->text;
+                    if ($otags = get_records_sql('SELECT * from '.$CFG->prefix.'tags WHERE type=\'official\' ORDER by text ASC')) {
+                        foreach ($otags as $otag) {
+                            echo '<br />'.$otag->text;
+                        }
                     }
                 }
             ?>