From c61860ee254a5fa94ff38eeaf5803e449743f794 Mon Sep 17 00:00:00 2001 From: Michael Haufe Date: Mon, 23 Sep 2024 14:10:57 +0000 Subject: [PATCH] Fixed ORM bug --- server/api/appusers/index.get.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/server/api/appusers/index.get.ts b/server/api/appusers/index.get.ts index 435cae52..958c1e7f 100644 --- a/server/api/appusers/index.get.ts +++ b/server/api/appusers/index.get.ts @@ -26,8 +26,7 @@ export default defineEventHandler(async (event) => { // assign the roles to the appusers const appUsersWithRoles: AppUserRoles[] = appUserOrganizationRoles.map((a) => ({ - // @ts-expect-error: The entity is actually in an 'entity' property. Is this an ORM bug? - ...a.appUser.entity, + ...a.appUser, role: a.role }))