fix: Return empty array instead of null for query_coords when no results

When vector visualization search returns zero results, the code was returning
query_coords: null, which caused JavaScript error "can't access property 0,
queryCoords is null" when the frontend tried to access the array.

Changed to return empty array [] to match expected type and prevent crash.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Chris Coutinho
2025-11-20 14:18:02 +01:00
parent d67aa6ae5c
commit 944dd760ca
+1 -1
View File
@@ -212,7 +212,7 @@ async def vector_visualization_search(request: Request) -> JSONResponse:
"success": True,
"results": [],
"coordinates_3d": [],
"query_coords": None,
"query_coords": [],
"message": "No results found",
}
)