Panel with ->domains option
I'm trying to make my Panel work for two specific domains using the ->domains() option. With php artisan optimize I get
The current domain is not set, but multiple domains are registered for the panel. Please use [Filament::currentDomain('example.com')] to set the current domain to ensure that panel URLs are generated correctly.
I've tried defining Filament::currentDomain('example.com') in various places but it didn't work out.
Can someone help me out?Solution:Jump to solution
Okay I think I found a workaround with:
```php
class GlobalPanelProvider extends PanelProvider
{...
2 Replies
Solution
Okay I think I found a workaround with:
I guess the best way would be to identify the domain inside a middlewar.