mirror of
https://code.castopod.org/adaures/castopod.git
synced 2024-09-27 20:21:59 +02:00
revert(install): reset condition to look for instance owner before continuing install
This commit is contained in:
parent
ab275e978c
commit
fc009f3d00
@ -115,8 +115,10 @@ class InstallController extends Controller
|
|||||||
}
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
$db = db_connect();
|
||||||
|
|
||||||
// Check if instance owner has been created, meaning install was completed
|
// Check if instance owner has been created, meaning install was completed
|
||||||
if ((new UserModel())->where('is_owner', true)
|
if ($db->tableExists('users') && (new UserModel())->where('is_owner', true)
|
||||||
->first() !== null
|
->first() !== null
|
||||||
) {
|
) {
|
||||||
// if so, show a 404 page
|
// if so, show a 404 page
|
||||||
|
@ -11,6 +11,7 @@ use Rector\CodingStyle\Rector\String_\SymplifyQuoteEscapeRector;
|
|||||||
use Rector\Config\RectorConfig;
|
use Rector\Config\RectorConfig;
|
||||||
use Rector\Core\ValueObject\PhpVersion;
|
use Rector\Core\ValueObject\PhpVersion;
|
||||||
use Rector\DeadCode\Rector\If_\UnwrapFutureCompatibleIfPhpVersionRector;
|
use Rector\DeadCode\Rector\If_\UnwrapFutureCompatibleIfPhpVersionRector;
|
||||||
|
use Rector\EarlyReturn\Rector\If_\ChangeAndIfToEarlyReturnRector;
|
||||||
use Rector\EarlyReturn\Rector\If_\ChangeOrIfContinueToMultiContinueRector;
|
use Rector\EarlyReturn\Rector\If_\ChangeOrIfContinueToMultiContinueRector;
|
||||||
use Rector\EarlyReturn\Rector\If_\ChangeOrIfReturnToEarlyReturnRector;
|
use Rector\EarlyReturn\Rector\If_\ChangeOrIfReturnToEarlyReturnRector;
|
||||||
use Rector\Php55\Rector\String_\StringClassNameToClassConstantRector;
|
use Rector\Php55\Rector\String_\StringClassNameToClassConstantRector;
|
||||||
@ -64,6 +65,8 @@ return static function (RectorConfig $rectorConfig): void {
|
|||||||
SymplifyQuoteEscapeRector::class => [__DIR__ . '/app/Language/*', __DIR__ . '/modules/*/Language/*'],
|
SymplifyQuoteEscapeRector::class => [__DIR__ . '/app/Language/*', __DIR__ . '/modules/*/Language/*'],
|
||||||
|
|
||||||
NewlineAfterStatementRector::class => [__DIR__ . '/app/Views'],
|
NewlineAfterStatementRector::class => [__DIR__ . '/app/Views'],
|
||||||
|
|
||||||
|
ChangeAndIfToEarlyReturnRector::class => [__DIR__ . '/modules/Install/Controllers/InstallController.php'],
|
||||||
]);
|
]);
|
||||||
|
|
||||||
// Path to phpstan with extensions, that PHPStan in Rector uses to determine types
|
// Path to phpstan with extensions, that PHPStan in Rector uses to determine types
|
||||||
|
Loading…
Reference in New Issue
Block a user