Add / to end of domain if not exists
This commit is contained in:
2
main.py
2
main.py
@ -17,6 +17,8 @@ try:
|
|||||||
domain = os.environ["DOMAIN"]
|
domain = os.environ["DOMAIN"]
|
||||||
except KeyError:
|
except KeyError:
|
||||||
sys.exit("Environment variable 'DOMAIN' is missing!")
|
sys.exit("Environment variable 'DOMAIN' is missing!")
|
||||||
|
if not domain.endswith("/"):
|
||||||
|
domain += "/"
|
||||||
|
|
||||||
|
|
||||||
@app.post("/uploadfiles/")
|
@app.post("/uploadfiles/")
|
||||||
|
Reference in New Issue
Block a user