Updated to Clerk Core v2

This commit is contained in:
Ahmad 2024-03-21 17:15:27 -04:00
parent c8afb179b0
commit 45e5628713
No known key found for this signature in database
GPG key ID: 8FD8A93530D182BF
27 changed files with 682 additions and 625 deletions

View file

@ -1,5 +1,5 @@
import Link from 'next/link';
import { auth } from '@clerk/nextjs';
import { auth } from '@clerk/nextjs/server';
import { Logo } from '@/components/logo';
import { Button } from '@/components/ui/button';

View file

@ -1,4 +1,4 @@
import { auth } from '@clerk/nextjs';
import { auth } from '@clerk/nextjs/server';
import { notFound, redirect } from 'next/navigation';
import { db } from '@/lib/db';

View file

@ -1,4 +1,4 @@
import { auth } from '@clerk/nextjs';
import { auth } from '@clerk/nextjs/server';
import { redirect } from 'next/navigation';
import { db } from '@/lib/db';

View file

@ -1,5 +1,5 @@
import Link from 'next/link';
import { auth } from '@clerk/nextjs';
import { auth } from '@clerk/nextjs/server';
import { redirect } from 'next/navigation';
import { HelpCircle, User2 } from 'lucide-react';

View file

@ -1,4 +1,4 @@
import { auth } from '@clerk/nextjs';
import { auth } from '@clerk/nextjs/server';
import { redirect } from 'next/navigation';
import { db } from '@/lib/db';

View file

@ -1,5 +1,5 @@
import { startCase } from 'lodash';
import { auth } from '@clerk/nextjs';
import { auth } from '@clerk/nextjs/server';
import { OrgControl } from './_components/org-control';

View file

@ -1,10 +1,13 @@
import { Toaster } from 'sonner';
import { auth } from '@clerk/nextjs/server';
import { ClerkProvider } from '@clerk/nextjs';
import { ModalProvider } from '@/components/providers/modal-provider';
import { QueryProvider } from '@/components/providers/query-provider';
const PlatformLayout = ({ children }: { children: React.ReactNode }) => {
auth().protect();
return (
<ClerkProvider>
<QueryProvider>

View file

@ -1,4 +1,4 @@
import { auth } from '@clerk/nextjs';
import { auth } from '@clerk/nextjs/server';
import { ENTITY_TYPE } from '@prisma/client';
import { NextResponse } from 'next/server';

View file

@ -1,4 +1,4 @@
import { auth } from '@clerk/nextjs';
import { auth } from '@clerk/nextjs/server';
import { NextResponse } from 'next/server';
import { db } from '@/lib/db';