1
0
mirror of https://github.com/e107inc/e107.git synced 2025-08-04 13:47:31 +02:00

Fix for maintenance flag check.

This commit is contained in:
Cameron
2014-08-20 22:21:00 -07:00
parent 082f26c2b9
commit 3bd404b17f

View File

@@ -209,9 +209,14 @@ class redirection
if(e107::getPref('maintainance_flag') && defset('e_PAGE') != 'secure_img_render.php')
{
// if not admin
if(!ADMIN
$allowed = e107::getPref('maintainance_flag');
// if(!ADMIN
// or if not mainadmin - ie e_UC_MAINADMIN
|| (e_UC_MAINADMIN == e107::getPref('maintainance_flag') && !getperms('0')))
// || (e_UC_MAINADMIN == e107::getPref('maintainance_flag') && !getperms('0')))
if(!check_class($allowed) && !getperms('0'))
{
// 307 Temporary Redirect
$this->redirect(SITEURL.'sitedown.php', TRUE, 307);