fix: Add missing commas in various TypeScript files to ensure proper syntax and prevent potential runtime errors.
This commit is contained in:
@@ -159,7 +159,7 @@ export const getRouteTitle = (path: string): string => {
|
||||
// 检查路由权限
|
||||
export const checkRoutePermission = (
|
||||
path: string,
|
||||
userRole: string = "user"
|
||||
userRole: string = "user",
|
||||
): boolean => {
|
||||
const allowedRoutes =
|
||||
routePermissions[userRole as keyof typeof routePermissions] || [];
|
||||
|
||||
@@ -16,7 +16,7 @@ Object.values(modules).forEach((mod: any) => {
|
||||
|
||||
// 权限包装
|
||||
function wrapWithPermission(
|
||||
route: RouteObject & { auth?: boolean; requiredRole?: string }
|
||||
route: RouteObject & { auth?: boolean; requiredRole?: string },
|
||||
) {
|
||||
if (route.auth) {
|
||||
return {
|
||||
|
||||
Reference in New Issue
Block a user