From 1ee17c3576afccb72c02c774c7a20c9ce0692e5e Mon Sep 17 00:00:00 2001 From: David Bomba Date: Sun, 28 Jun 2020 21:52:45 +1000 Subject: [PATCH] Minor fixes for setup process --- VERSION.txt | 2 +- app/Http/Controllers/SetupController.php | 6 ++++++ config/ninja.php | 2 +- 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/VERSION.txt b/VERSION.txt index 0147f9e738aa..3fc3a24531b5 100644 --- a/VERSION.txt +++ b/VERSION.txt @@ -1 +1 @@ -5.0.7 \ No newline at end of file +5.0.9 \ No newline at end of file diff --git a/app/Http/Controllers/SetupController.php b/app/Http/Controllers/SetupController.php index b1d412dae389..152444ccea76 100644 --- a/app/Http/Controllers/SetupController.php +++ b/app/Http/Controllers/SetupController.php @@ -19,6 +19,7 @@ use App\Models\Account; use App\Utils\SystemHealth; use Illuminate\Http\Response; use Illuminate\Support\Facades\Artisan; +use Illuminate\Support\Facades\Schema; /** * Class SetupController. @@ -34,6 +35,11 @@ class SetupController extends Controller { $check = SystemHealth::check(); + if($check['system_health'] == "true" && Schema::hasTable('accounts') && $account = Account::all()->first()) + return redirect('/'); + + $check = SystemHealth::check(); + return view('setup.index', ['check' => $check]); } diff --git a/config/ninja.php b/config/ninja.php index 211f93fa663f..c863062feb48 100644 --- a/config/ninja.php +++ b/config/ninja.php @@ -12,7 +12,7 @@ return [ 'require_https' => env('REQUIRE_HTTPS', true), 'app_url' => env('APP_URL', ''), 'app_domain' => env('APP_DOMAIN', ''), - 'app_version' => '5.0.7', + 'app_version' => '5.0.9', 'minimum_client_version' => '5.0.11', 'terms_version' => '1.0.1', 'api_secret' => env('API_SECRET', ''),