Installer tweak to aid with IIS setup: if config.php exists, but is both empty and writable, let the installer proceed and overwrite it.
This commit is contained in:
parent
17ab15a3d0
commit
9bb48c36ea
@ -81,10 +81,13 @@ abstract class Installer
|
|||||||
{
|
{
|
||||||
$pass = true;
|
$pass = true;
|
||||||
|
|
||||||
if (file_exists(INSTALLDIR.'/config.php')) {
|
$config = INSTALLDIR.'/config.php';
|
||||||
|
if (file_exists($config)) {
|
||||||
|
if (!is_writable($config) || filesize($config) > 0) {
|
||||||
$this->warning('Config file "config.php" already exists.');
|
$this->warning('Config file "config.php" already exists.');
|
||||||
$pass = false;
|
$pass = false;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (version_compare(PHP_VERSION, '5.2.3', '<')) {
|
if (version_compare(PHP_VERSION, '5.2.3', '<')) {
|
||||||
$errors[] = 'Require PHP version 5.2.3 or greater.';
|
$errors[] = 'Require PHP version 5.2.3 or greater.';
|
||||||
|
Loading…
Reference in New Issue
Block a user