mirror of
https://github.com/andrewkdinh/simple-contact.git
synced 2024-10-10 07:24:44 -07:00
Change how ESCAPE_HTML set
This commit is contained in:
parent
5cc68b7d0a
commit
7860d0ef3e
11
main.py
11
main.py
@ -13,16 +13,7 @@ if not HTTP_ENDPOINT:
|
||||
print("ERROR: HTTP_ENDPOINT not set")
|
||||
exit(1)
|
||||
|
||||
if not ESCAPE_HTML:
|
||||
print("ERROR: ESCAPE_HTML not set")
|
||||
exit(1)
|
||||
if ESCAPE_HTML == "True":
|
||||
ESCAPE_HTML = True
|
||||
elif ESCAPE_HTML == "False":
|
||||
ESCAPE_HTML = False
|
||||
else:
|
||||
print("ERROR: ESCAPE_HTML must be set to True or False")
|
||||
exit(1)
|
||||
ESCAPE_HTML = ESCAPE_HTML and ESCAPE_HTML == "True"
|
||||
|
||||
@app.route("/", methods=["GET", "POST"])
|
||||
def index():
|
||||
|
Loading…
Reference in New Issue
Block a user