MDL-56050 core: set missing context to maintenance mode
[moodle.git] / lib / moodlelib.php
index cb08387..8fcfe70 100644 (file)
@@ -2716,7 +2716,7 @@ function require_login($courseorid = null, $autologinguest = true, $cm = null, $
         if ($preventredirect) {
             throw new require_login_exception('Maintenance in progress');
         }
-
+        $PAGE->set_context(null);
         print_maintenance_message();
     }