Mythus commited on
Commit
29e7f06
·
verified ·
1 Parent(s): dcda4aa

Update run.py

Browse files
Files changed (1) hide show
  1. run.py +6 -1
run.py CHANGED
@@ -19,7 +19,12 @@ app = FastAPI(lifespan=close_proxy_event)
19
 
20
  @app.get("/{path:path}")
21
  async def _(request: Request, path: str = ""):
22
- return await proxy.proxy(request=request, path=path)
 
 
 
 
 
23
 
24
 
25
  if __name__ == '__main__':
 
19
 
20
  @app.get("/{path:path}")
21
  async def _(request: Request, path: str = ""):
22
+ response = await proxy.proxy(request=request, path=path)
23
+ return Response(
24
+ content=response.content,
25
+ status_code=response.status_code,
26
+ headers=dict(response.headers)
27
+ )
28
 
29
 
30
  if __name__ == '__main__':