Remove API_ROOT
This commit is contained in:
7
app.py
7
app.py
@@ -189,17 +189,14 @@ class Room:
|
|||||||
rooms: dict[str, Room] = {}
|
rooms: dict[str, Room] = {}
|
||||||
|
|
||||||
|
|
||||||
API_ROOT = "http://127.0.0.1:8989"
|
|
||||||
|
|
||||||
|
|
||||||
@app.GET("/")
|
@app.GET("/")
|
||||||
async def home(request):
|
async def home(request):
|
||||||
return render(request, "index.html", {"API_ROOT": API_ROOT})
|
return render(request, "index.html")
|
||||||
|
|
||||||
|
|
||||||
@app.GET("/<id>")
|
@app.GET("/<id>")
|
||||||
async def home_with_id(request, id):
|
async def home_with_id(request, id):
|
||||||
return render(request, "index.html", {"API_ROOT": API_ROOT})
|
return render(request, "index.html")
|
||||||
|
|
||||||
|
|
||||||
@app.POST("/join/<room_id>")
|
@app.POST("/join/<room_id>")
|
||||||
|
|||||||
Reference in New Issue
Block a user