diff options
| author | Dhravya <[email protected]> | 2024-04-03 00:14:07 -0700 |
|---|---|---|
| committer | Dhravya <[email protected]> | 2024-04-03 00:14:07 -0700 |
| commit | 4ff97a09049bdf755146db1699eb534270e01ff4 (patch) | |
| tree | 47744225a3c8a5ef2366a75197805e2f6092ff48 /apps/web/src/components/QueryAI.tsx | |
| parent | Merge branch 'new-ui' of https://github.com/Dhravya/supermemory into new-ui (diff) | |
| parent | change 'categories' to 'spaces' (diff) | |
| download | supermemory-4ff97a09049bdf755146db1699eb534270e01ff4.tar.xz supermemory-4ff97a09049bdf755146db1699eb534270e01ff4.zip | |
update: catch up with main
Diffstat (limited to 'apps/web/src/components/QueryAI.tsx')
| -rw-r--r-- | apps/web/src/components/QueryAI.tsx | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/apps/web/src/components/QueryAI.tsx b/apps/web/src/components/QueryAI.tsx index 811dd899..3cb14178 100644 --- a/apps/web/src/components/QueryAI.tsx +++ b/apps/web/src/components/QueryAI.tsx @@ -82,6 +82,11 @@ function QueryAI() { const response = await fetch(`/api/query?q=${input}`); + if (response.status !== 200) { + setIsAiLoading(false); + return; + } + if (response.body) { let reader = response.body.getReader(); let decoder = new TextDecoder('utf-8'); |