From 65e9b0c5f36530163cb028deb06b74cabb256695 Mon Sep 17 00:00:00 2001
From: jisangs
Date: Sun, 5 Jul 2026 12:24:48 +0900
Subject: [PATCH] =?UTF-8?q?=EB=A1=9C=EA=B7=B8=EC=95=84=EC=9B=83=EC=9D=84?=
=?UTF-8?q?=20=EB=AA=A8=EB=93=88=20=EC=88=98=EC=A4=80=20=EC=84=9C=EB=B2=84?=
=?UTF-8?q?=20=EC=95=A1=EC=85=98=EC=9C=BC=EB=A1=9C=20=EB=B3=80=ED=99=98=20?=
=?UTF-8?q?(=EB=B9=8C=EB=93=9C=20=EA=B0=84=20=EC=95=A1=EC=85=98=20ID=20?=
=?UTF-8?q?=EC=95=88=EC=A0=95=ED=99=94)?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
app/(admin)/actions.ts | 10 ++++++++++
app/(admin)/layout.tsx | 13 ++++---------
2 files changed, 14 insertions(+), 9 deletions(-)
create mode 100644 app/(admin)/actions.ts
diff --git a/app/(admin)/actions.ts b/app/(admin)/actions.ts
new file mode 100644
index 0000000..0cdc757
--- /dev/null
+++ b/app/(admin)/actions.ts
@@ -0,0 +1,10 @@
+"use server";
+
+import { redirect } from "next/navigation";
+
+import { signOut } from "@/auth";
+
+export async function logoutAction() {
+ await signOut({ redirect: false });
+ redirect("/login");
+}
diff --git a/app/(admin)/layout.tsx b/app/(admin)/layout.tsx
index b8b2581..8e59100 100644
--- a/app/(admin)/layout.tsx
+++ b/app/(admin)/layout.tsx
@@ -8,9 +8,11 @@ import {
LogOut,
} from "lucide-react";
-import { auth, signOut } from "@/auth";
+import { auth } from "@/auth";
import { Button } from "@/components/ui/button";
+import { logoutAction } from "./actions";
+
const navItems = [
{ href: "/", label: "대시보드", icon: LayoutDashboard },
{ href: "/maestros", label: "마에스트로", icon: GraduationCap },
@@ -63,14 +65,7 @@ export default async function AdminLayout({
관리자 ID {session.user.adminID}
-