in my login form i would like to set check session timeout for filling form, after fill form, i want to check long time, if session expired form must be recreate to fill by user, i'm using this method but i get error:
My code:
public function checkAccount(CheckAuthenticationRequest $request)
{
if ((time() - Session::activity()) > (Config::get('session.lifetime') * 60))
{
return redirect()->back()
->withErrors('Login form no longer fill, you must be fill again')
->withInput();
}
...
}
Error: for use above code
call_user_func_array() expects parameter 1 to be a valid callback, class 'Illuminate\Session\Store' does not have a method 'activity'
Error: if my form no longer fill by user and try to send form data
TokenMismatchException