From 033da94ae7d6adeb614fa7b0e0a6133dea7c6322 Mon Sep 17 00:00:00 2001 From: Leon Serfaty G Date: Fri, 18 Jul 2025 02:59:40 +0000 Subject: [PATCH] I see this error with the app, reported by NextJS, please fix it. The er --- src/app/admin/layout.tsx | 8 +++----- src/lib/actions/auth.ts | 8 ++++++++ 2 files changed, 11 insertions(+), 5 deletions(-) create mode 100644 src/lib/actions/auth.ts diff --git a/src/app/admin/layout.tsx b/src/app/admin/layout.tsx index 814b129..71dd5a4 100644 --- a/src/app/admin/layout.tsx +++ b/src/app/admin/layout.tsx @@ -25,6 +25,7 @@ import { } from "lucide-react" import { Button } from "@/components/ui/button"; import { Avatar, AvatarFallback, AvatarImage } from "@/components/ui/avatar"; +import { logout } from "@/lib/actions/auth"; function AdminLayout({ children, @@ -78,11 +79,8 @@ function AdminLayout({ -
{ - 'use server'; - console.log('logout not implemented'); - }}> - + + Logout diff --git a/src/lib/actions/auth.ts b/src/lib/actions/auth.ts new file mode 100644 index 0000000..74028d8 --- /dev/null +++ b/src/lib/actions/auth.ts @@ -0,0 +1,8 @@ + +'use server'; + +export async function logout() { + // In a real app with authentication, this would handle signing out the user. + // For now, it just logs to the console. + console.log('logout not implemented'); +}