MDL-56514 core_message: remove messaging enabled check
authorSimey Lameze <simey@moodle.com>
Tue, 1 Nov 2016 06:15:32 +0000 (14:15 +0800)
committerSimey Lameze <simey@moodle.com>
Tue, 1 Nov 2016 06:15:32 +0000 (14:15 +0800)
message/externallib.php

index e86f581..6e81c4f 100644 (file)
@@ -2306,11 +2306,6 @@ class core_message_external extends external_api {
     public static function get_user_notification_preferences($userid = 0) {
         global $USER, $PAGE, $CFG;
 
-        // Check if messaging is enabled.
-        if (empty($CFG->messaging)) {
-            throw new moodle_exception('disabled', 'message');
-        }
-
         $params = self::validate_parameters(
             self::get_user_notification_preferences_parameters(),
             array(