F
Filament6mo ago
jw

Filament::getPanel('user')->getUrl(); - Potential Bug?

Hello, I was calling this function within a loop. The first time it correctly gives me the 'user' panel URL. On subsequent calls it seems to ignore the 'user' parameter and returns the url of the default panel ('admin'). I tried splitting the function out to: $panel = Filament::getPanel('user'); $url = $panel->getUrl(); Has anyone come across this before or could offer an explanation? Thanks
7 Replies
Dennis Koch
Dennis Koch6mo ago
Sounds weird. Where are you calling this from?
jw
jwOP6mo ago
Thanks for the quick response. Some additional information:
No description
No description
Dennis Koch
Dennis Koch6mo ago
That code is quite a bit different though. First one used $this (is that on a page? second one NavigationItem`
jw
jwOP6mo ago
No description
jw
jwOP6mo ago
The first two images I sent are from the Filament codebase "namespace Filament\Panel\Concerns\HasRoutes.php" It's strange, as it's giving me a different result between iterations of a loop, calling the same code
jw
jwOP6mo ago
No description
jw
jwOP6mo ago
Hi @Dennis Koch, did I provide enough information? Please let me know if you need anything more. Thanks again for your assistance
Want results from more Discord servers?
Add your server