Skip to content

Commit

Permalink
Fix: Undefined Supabase
Browse files Browse the repository at this point in the history
  • Loading branch information
sshivaditya committed Mar 10, 2024
1 parent bc6cadd commit 104c36d
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/lib/memory.ts
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,10 @@ export class MemoryManager {
query_field_sub_name: 'content',
query_match_count: 10,
};

if (this.runtime.supabase === null) {
return [];
}
const result = await this.runtime.supabase.rpc("get_embedding_list", opts);
if (result.error) {
throw new Error(JSON.stringify(result.error));
Expand Down

0 comments on commit 104c36d

Please sign in to comment.