Skip to content

Commit 97748a2

Browse files
authored
Same error as in ENG-675: dbDotEnv should not be used in client. (#323)
1 parent 2a1b0ad commit 97748a2

1 file changed

Lines changed: 2 additions & 4 deletions

File tree

apps/website/app/utils/supabase/client.ts

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,11 @@
11
import { createClient as createSupabaseClient } from "@supabase/supabase-js";
22
import { Database } from "@repo/database/types.gen.ts";
3-
import { envContents } from "@repo/database/dbDotEnv";
43

54
// Inspired by https://supabase.com/ui/docs/nextjs/password-based-auth
65

76
export const createClient = () => {
8-
const dbEnv = envContents();
9-
const url = dbEnv.SUPABASE_URL;
10-
const key = dbEnv.SUPABASE_ANON_KEY;
7+
const url = process.env.SUPABASE_URL;
8+
const key = process.env.SUPABASE_ANON_KEY;
119

1210
if (!url || !key) {
1311
throw new Error("Missing required Supabase environment variables");

0 commit comments

Comments
 (0)