diff --git a/bootstrap.php b/bootstrap.php index b06e11a..831dff3 100644 --- a/bootstrap.php +++ b/bootstrap.php @@ -79,7 +79,8 @@ if (!empty($_SERVER['REQUEST_URI'])) { $allowed = !file_exists($CFG->dataroot.'/climaintenance.php') // Not in maintenance mode. || (defined('ABORT_AFTER_CONFIG') && ABORT_AFTER_CONFIG) // Only config requested. || (defined('CLI_SCRIPT') && CLI_SCRIPT) // Allow CLI scripts. - || $outageinfo; // Allow outage info requests. + || $outageinfo // Allow outage info requests. + || (defined('NO_AUTH_OUTAGE') && NO_AUTH_OUTAGE); // Allow any page should not be blocked by maintenance mode. if (!$allowed) { // Call the climaintenance.php which will check for allowed IPs. $CFG->dirroot = dirname(dirname(dirname(__FILE__))); // It is not defined yet but the script below needs it. diff --git a/checkfinished.php b/checkfinished.php index ad8e69d..e090ad5 100644 --- a/checkfinished.php +++ b/checkfinished.php @@ -27,6 +27,7 @@ use auth_outage\dml\outagedb; define('NO_MOODLE_COOKIES', true); header('Cache-Control: public, max-age=10,s-maxage=10'); +define('NO_AUTH_OUTAGE', true); require_once(__DIR__.'/../../config.php');