fix API 404 response to return exception detail, add WebSocket RF alias
This commit is contained in:
@@ -14,7 +14,7 @@ async def not_found_handler(request: Request, exc: HTTPException):
|
||||
if request.url.path.startswith("/api/"):
|
||||
return JSONResponse(
|
||||
status_code=404,
|
||||
content={"detail": "API endpoint not found"}
|
||||
content={"detail": exc.detail}
|
||||
)
|
||||
return render_template(
|
||||
"error.html",
|
||||
|
||||
Reference in New Issue
Block a user