Skip to content

Commit f8d335b

Browse files
committed
fix: avoid duplicate fetches
1 parent 7713dd1 commit f8d335b

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/lib/components/billing/alerts/selectProjectCloud.svelte

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,11 @@
2424
let error = $state<string | null>(null);
2525
2626
onMount(() => {
27-
projects = page.data.allProjects?.projects || [];
27+
const currentOrgId = page.data.organization?.$id;
28+
projects =
29+
page.data.currentOrgId === currentOrgId
30+
? page.data.allProjects?.projects || []
31+
: [];
2832
});
2933
3034
let projectsToArchive = $derived(

0 commit comments

Comments
 (0)