Merge pull request #5833 from MrPetovan/develop
Replace remaining $a->isInstallMode() instances
This commit is contained in:
commit
dc49ad090e
7 changed files with 8 additions and 8 deletions
|
@ -34,7 +34,7 @@ require_once "include/dba.php";
|
||||||
|
|
||||||
$a = new App(dirname(__DIR__));
|
$a = new App(dirname(__DIR__));
|
||||||
|
|
||||||
if ($a->isInstallMode()) {
|
if (App\Mode::isInstall()) {
|
||||||
die("Friendica isn't properly installed yet.\n");
|
die("Friendica isn't properly installed yet.\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -165,9 +165,9 @@ $_SESSION['last_updated'] = defaults($_SESSION, 'last_updated', []);
|
||||||
|
|
||||||
// in install mode, any url loads install module
|
// in install mode, any url loads install module
|
||||||
// but we need "view" module for stylesheet
|
// but we need "view" module for stylesheet
|
||||||
if ($a->isInstallMode() && $a->module!="view") {
|
if (App\Mode::isInstall() && $a->module != 'view') {
|
||||||
$a->module = 'install';
|
$a->module = 'install';
|
||||||
} elseif (!App\Mode::has(App\Mode::MAINTENANCEDISABLED) && $a->module != "view") {
|
} elseif (!App\Mode::has(App\Mode::MAINTENANCEDISABLED) && $a->module != 'view') {
|
||||||
$a->module = 'maintenance';
|
$a->module = 'maintenance';
|
||||||
} else {
|
} else {
|
||||||
check_url($a);
|
check_url($a);
|
||||||
|
|
|
@ -56,7 +56,7 @@ HELP;
|
||||||
throw new \Asika\SimpleConsole\CommandArgsException('Too many arguments');
|
throw new \Asika\SimpleConsole\CommandArgsException('Too many arguments');
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($a->isInstallMode()) {
|
if (App\Mode::isInstall()) {
|
||||||
throw new \RuntimeException('Database isn\'t ready or populated yet');
|
throw new \RuntimeException('Database isn\'t ready or populated yet');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -65,7 +65,7 @@ HELP;
|
||||||
throw new \Asika\SimpleConsole\CommandArgsException('Too many arguments');
|
throw new \Asika\SimpleConsole\CommandArgsException('Too many arguments');
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($a->isInstallMode()) {
|
if (App\Mode::isInstall()) {
|
||||||
throw new RuntimeException('Database isn\'t ready or populated yet');
|
throw new RuntimeException('Database isn\'t ready or populated yet');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -64,7 +64,7 @@ HELP;
|
||||||
throw new \Asika\SimpleConsole\CommandArgsException('Too many arguments');
|
throw new \Asika\SimpleConsole\CommandArgsException('Too many arguments');
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($a->isInstallMode()) {
|
if (App\Mode::isInstall()) {
|
||||||
throw new \RuntimeException('Database isn\'t ready or populated yet');
|
throw new \RuntimeException('Database isn\'t ready or populated yet');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -57,7 +57,7 @@ HELP;
|
||||||
throw new \Asika\SimpleConsole\CommandArgsException('Too many arguments');
|
throw new \Asika\SimpleConsole\CommandArgsException('Too many arguments');
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($a->isInstallMode()) {
|
if (App\Mode::isInstall()) {
|
||||||
throw new RuntimeException('Database isn\'t ready or populated yet');
|
throw new RuntimeException('Database isn\'t ready or populated yet');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -50,7 +50,7 @@ HELP;
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($a->isInstallMode()) {
|
if (App\Mode::isInstall()) {
|
||||||
throw new \RuntimeException('Database isn\'t ready or populated yet');
|
throw new \RuntimeException('Database isn\'t ready or populated yet');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue