]> git.mjollnir.org Git - moodle.git/commitdiff
Take out one notice when the only activity was
authorstronk7 <stronk7>
Wed, 22 Oct 2003 16:19:21 +0000 (16:19 +0000)
committerstronk7 <stronk7>
Wed, 22 Oct 2003 16:19:21 +0000 (16:19 +0000)
create a module and delete it. Strange but possible. :-)

course/lib.php

index af82da58a4af47d43dfb2d7dbbdb8d6d5defbd06..e2003bc18a86bd8c37becdfe3ce0cc37fc477666 100644 (file)
@@ -308,11 +308,13 @@ function print_recent_activity($course) {
                 $changes[$changeinfo] = $change;
             }
         }
-        if (count($changes) > 0) {
-            print_headline(get_string("courseupdates").":");
-            $content = true;
-            foreach ($changes as $changeinfo => $change) {
-                echo "<p><font size=1>".$change["text"]."</font></p>";
+        if (isset($changes)){
+            if (count($changes) > 0) {
+                print_headline(get_string("courseupdates").":");
+                $content = true;
+                foreach ($changes as $changeinfo => $change) {
+                    echo "<p><font size=1>".$change["text"]."</font></p>";
+                }
             }
         }
     }