FEATURE: redirect to last page when session has expired

This commit is contained in:
Michal Kváček
2016-08-25 01:03:35 +02:00
parent f1121107c5
commit 8458622e32
3 changed files with 8 additions and 5 deletions
+3 -1
View File
@@ -23,7 +23,9 @@ class Authenticate
return response('Unauthorized.', 401);
}
return redirect()->route('login');
return redirect()
->route('login')
->with('redirectTo', $request->fullUrl());
}
return $next($request);