Skip to content
This repository has been archived by the owner on Aug 7, 2023. It is now read-only.

Flask before_request CannotSendRequest #304

Answered by lthon09
lthon09 asked this question in Help
Discussion options

You must be logged in to vote

heres the code btw:

@_app.before_request # TODO: fix
def before_request():
    if app.get("maintenance")["value"]:
        return render_template("error.html", code=503, name="Undergoing Maintenance", message="We're on maintenance, come back later!"), 503

Replies: 2 comments 5 replies

Comment options

You must be logged in to vote
1 reply
@lthon09
Comment options

Comment options

You must be logged in to vote
4 replies
@abdelhai
Comment options

@lthon09
Comment options

@abdelhai
Comment options

@lthon09
Comment options

Answer selected by lthon09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Help
Labels
None yet
3 participants