Skip to content

Commit

Permalink
Fix website build
Browse files Browse the repository at this point in the history
  • Loading branch information
cp-dharti-r committed May 15, 2024
1 parent baddeb1 commit 2b6357d
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 8 deletions.
1 change: 1 addition & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ jobs:
else
echo "No changes detected in the website folder after build. Exiting."
fi
- name: Merge admin branch to admin-main
run: |
git fetch origin
Expand Down
4 changes: 2 additions & 2 deletions website/utils/supabase.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { createClient } from "@supabase/supabase-js";

export default createClient(
process.env.SUPABASE_URL!,
process.env.SUPABASE_ANON_KEY!
process.env.NEXT_PUBLIC_SUPABASE_URL!,
process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!
);
4 changes: 2 additions & 2 deletions website/utils/supabase/client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@ import { createBrowserClient } from "@supabase/ssr";

export const createClient = () =>
createBrowserClient(
process.env.SUPABASE_URL!,
process.env.SUPABASE_ANON_KEY!
process.env.NEXT_PUBLIC_SUPABASE_URL!,
process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!
);
4 changes: 2 additions & 2 deletions website/utils/supabase/middleware.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ export const createClient = (request: NextRequest) => {
});

const supabase = createServerClient(
process.env.SUPABASE_URL!,
process.env.SUPABASE_ANON_KEY!,
process.env.NEXT_PUBLIC_SUPABASE_URL!,
process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!,
{
cookies: {
get(name: string) {
Expand Down
4 changes: 2 additions & 2 deletions website/utils/supabase/server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ import { cookies } from "next/headers";

export const createClient = (cookieStore: ReturnType<typeof cookies>) => {
return createServerClient(
process.env.SUPABASE_URL!,
process.env.SUPABASE_ANON_KEY!,
process.env.NEXT_PUBLIC_SUPABASE_URL!,
process.env.NEXT_PUBLIC_SUPABASE_ANON_KEY!,
{
cookies: {
get(name: string) {
Expand Down

0 comments on commit 2b6357d

Please sign in to comment.