diff --git a/app/Livewire/Admin/Index.php b/app/Livewire/Admin/Index.php index 4fe430538..888a29233 100644 --- a/app/Livewire/Admin/Index.php +++ b/app/Livewire/Admin/Index.php @@ -11,7 +11,7 @@ class Index extends Component public $users = []; public function mount() { - if (isInstanceAdmin() && session('adminToken') === null) { + if (!isInstanceAdmin() && session('adminToken') === null) { return redirect()->route('dashboard'); } $this->users = User::whereHas('teams', function ($query) { diff --git a/resources/views/components/navbar.blade.php b/resources/views/components/navbar.blade.php index e4cafb6b9..04ce6257f 100644 --- a/resources/views/components/navbar.blade.php +++ b/resources/views/components/navbar.blade.php @@ -142,7 +142,7 @@ class="{{ request()->is('settings*') ? 'text-warning icon' : 'icon' }}" - @if (isCloud()) + @if (isCloud() && isInstanceAdmin())