mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-04-02 01:52:10 +09:00
Allow sitelock immediately after install (#160)
This commit is contained in:
parent
9e9b09464f
commit
605fdec1a2
10 changed files with 84 additions and 10 deletions
|
|
@ -234,6 +234,16 @@ class installController extends install
|
|||
}
|
||||
}
|
||||
|
||||
// Apply site lock.
|
||||
|
||||
if (Context::get('use_sitelock') === 'Y')
|
||||
{
|
||||
$user_ip_range = getView('install')->detectUserIPRange();
|
||||
Rhymix\Framework\Config::set('lock.locked', true);
|
||||
Rhymix\Framework\Config::set('lock.message', 'This site is locked.');
|
||||
Rhymix\Framework\Config::set('lock.allow', array('127.0.0.1', $user_ip_range));
|
||||
}
|
||||
|
||||
// Save the new configuration.
|
||||
Rhymix\Framework\Config::save();
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue