App\Controllers\Admin\AuthController::logout PHP Method

logout() public method

public logout ( $req, $res )
    public function logout($req, $res)
    {
        Session::forget('auth');
        Session::forget('user');
        return $res->withStatus(301)->withHeader('Location', $this->router->pathFor('login'));
    }