Skip to content

Commit 9d3fd64

Browse files
fix/revalidate path if repo added
1 parent d673602 commit 9d3fd64

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

src/app/(dynamic-pages)/(login-pages)/auth/callback/route.ts

-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@ export async function GET(request: Request) {
2626
// HACK_ALERT!!!
2727
// cookie is probably set on 'next.digger.dev' we have to change it to `.digger.dev`
2828
const cookieKey = `sb-${process.env.SUPABASE_PROJECT_REF}-auth-token`;
29-
const cookieValue = cookies().get(cookieKey)?.value;
3029
const cookieStore = cookies();
3130
const currentCookieValue = cookieStore.get(cookieKey)?.value;
3231
// get domain of current reques

src/data/user/repos.ts

+3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
'use server';
22

33
import { createSupabaseUserServerComponentClient } from '@/supabase-clients/user/createSupabaseUserServerComponentClient';
4+
import { revalidatePath } from 'next/cache';
45

56
export async function getRepoDetails(repoId: number) {
67
const supabaseClient = createSupabaseUserServerComponentClient();
@@ -28,5 +29,7 @@ export async function getOrganizationRepos(organizationId: string) {
2829
throw error;
2930
}
3031

32+
revalidatePath(`/org/${organizationId}/projects/create`, 'page');
33+
3134
return data;
3235
}

0 commit comments

Comments
 (0)