inventorymgr/auth.py
def logout() -> Any:
    """Flask view to log a user out."""
    if "user_id" in session:
        del session["user_id"]
    response = make_response({"success": True})
    response.set_cookie("is_authenticated", max_age=0, expires=0)
    return response
Flask view to log a user out.
Flask view to log a user out.
Flask view to log a user out .
def logout() -> Any:
    if "user_id" in session:
        del session["user_id"]
    response = make_response({"success": True})
    response.set_cookie("is_authenticated", max_age=0, expires=0)
    return response
def logout ( ) -> Any : if "user_id" in session : del session [ "user_id" ] response = make_response ( { "success" : True } ) response . set_cookie ( "is_authenticated" , max_age = 0 , expires = 0 ) return response
Flask view to log a user out.
Flask view to log a user out .
"""Flask view to log a user out."""