Skip to content

Commit

Permalink
Merge pull request #24 from OccTherapist/3.x
Browse files Browse the repository at this point in the history
fixes bug #23 - with wrong routes for unauthenticated multinenancy users
  • Loading branch information
JibayMcs authored Nov 5, 2024
2 parents c6cc26b + efd2e93 commit 82e2019
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/Tour/Traits/CanConstructRoute.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,10 @@ public function getRoute($class): array|false|int|null|string
return $this->route;
}

if (!Filament::auth()->user()) {
return '/';
}

if (Filament::getCurrentPanel()->getTenantModel()) {

$tenants = Filament::getCurrentPanel()->getTenantModel()::find(Filament::auth()->user()->getTenants(Filament::getCurrentPanel()));
Expand Down

0 comments on commit 82e2019

Please sign in to comment.