From 6a00748563c9c846c23bc999681a702510dd1954 Mon Sep 17 00:00:00 2001 From: cp6 Date: Sun, 20 Feb 2022 22:43:38 +1100 Subject: [PATCH] Updated servers public page Updated servers public page to show if logged in --- app/Http/Controllers/ServerController.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Http/Controllers/ServerController.php b/app/Http/Controllers/ServerController.php index 4d7e436..e83da6b 100644 --- a/app/Http/Controllers/ServerController.php +++ b/app/Http/Controllers/ServerController.php @@ -9,6 +9,7 @@ use App\Models\Server; use App\Models\Providers; use App\Models\Locations; use Illuminate\Http\Request; +use Illuminate\Support\Facades\Auth; use Illuminate\Support\Facades\Config; use Illuminate\Support\Facades\Session; use Illuminate\Support\Str; @@ -38,9 +39,8 @@ class ServerController extends Controller Session::put('timer_version_footer', $settings[0]->show_versions_footer); Session::put('show_servers_public', $settings[0]->show_servers_public); Session::save(); - // dd(Session::all()); - if (Session::has('show_servers_public') && Session::get('show_servers_public') === 1) { + if ((Session::has('show_servers_public') && Session::get('show_servers_public') === 1) || Auth::check()) { $servers = DB::table('servers as s') ->Join('pricings as pr', 's.id', '=', 'pr.service_id') ->Join('providers as p', 's.provider_id', '=', 'p.id')