]> git.mjollnir.org Git - moodle.git/commitdiff
turn this block off when $CFG->messaging is off
authortoyomoyo <toyomoyo>
Thu, 22 Nov 2007 01:17:03 +0000 (01:17 +0000)
committertoyomoyo <toyomoyo>
Thu, 22 Nov 2007 01:17:03 +0000 (01:17 +0000)
blocks/messages/block_messages.php

index 3d211854155227dfcb9e8949dfc3d63e5a07d0d0..93589364e91d7104a0497e936cfeceb96f4d58b4 100644 (file)
@@ -9,6 +9,10 @@ class block_messages extends block_base {
     function get_content() {
         global $USER, $CFG;
 
+        if (!$CFG->messaging) {
+            return ''; 
+        }
+
         if ($this->content !== NULL) {
             return $this->content;
         }