This commit is contained in:
2026-04-19 13:23:00 +03:00
parent e4c74025e5
commit 1346924387
25 changed files with 1639 additions and 1076 deletions
+12
View File
@@ -0,0 +1,12 @@
import { UserRole } from "@prisma/client";
export const APP_ROLES = {
user: UserRole.user,
superadmin: UserRole.superadmin,
} as const;
export const ADMIN_ROLES = [APP_ROLES.superadmin] as const;
export function normalizeRole(role: string | null | undefined): string {
return role?.trim().toLowerCase() ?? "";
}