FilamentF
Filament16mo ago
AgonK

auth()->user cannot be read after login in middleware ?

I have created a middleware and placed in app.php file on laravel side. I try to read value in every request but the problem is that I can't read any property from auth() after login. Yes, on the first request the auth() does not exist, but after login it should be readable. Moreover, I have placed some data in the Session::put('some_data', $data), even these data do not exist(I checked with debug).

Thank you anyway!
Was this page helpful?