mirror of
https://github.com/Galax028/startpage.git
synced 2025-02-16 10:59:25 +01:00
Fix things
This commit is contained in:
parent
dd1fe07e53
commit
f1f345b5da
5
proxy.py
5
proxy.py
@ -4,12 +4,13 @@ from flask import Flask, send_from_directory
|
|||||||
server = Flask(__name__)
|
server = Flask(__name__)
|
||||||
|
|
||||||
|
|
||||||
|
@server.get("/")
|
||||||
@server.get("/<string:file>")
|
@server.get("/<string:file>")
|
||||||
def startpage(file = None):
|
def startpage(file = None):
|
||||||
if not file:
|
if not file:
|
||||||
return send_from_directory("/", "startpage.html")
|
return send_from_directory("./", "startpage.html")
|
||||||
else:
|
else:
|
||||||
return send_from_directory("/", file)
|
return send_from_directory("./", file)
|
||||||
|
|
||||||
|
|
||||||
@server.get("/ac/<string:query>")
|
@server.get("/ac/<string:query>")
|
||||||
|
@ -8,8 +8,8 @@
|
|||||||
],
|
],
|
||||||
"routes": [
|
"routes": [
|
||||||
{
|
{
|
||||||
"src": "./(.*)",
|
"src": "/(.*)",
|
||||||
"dest": "./"
|
"dest": "/"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
Loading…
Reference in New Issue
Block a user