I've following configuration of session in config/session.php
/*
|--------------------------------------------------------------------------
| Session Lifetime
|--------------------------------------------------------------------------
|
| Here you may specify the number of minutes that you wish the session
| to be allowed to remain idle before it expires. If you want them
| to immediately expire on the browser closing, set that option.
|
*/
'lifetime' => env('SESSION_LIFETIME', 5),
'expire_on_close' => true,
I've made session expire when user is inactive for 5 minutes and redirect to login. It works for all routes and redirect user to login but after session expire when user sends logout request it shows
The page has expired due to inactivity. Please refresh and try again.
For all other routes it works correctly.
What I should do to to fix this ?
NOTE: I've already seen following questions. None works for me.
Redirect automatically when user session expires in Laravel 5.5