diff --git a/server/ProcDecorator/ReqLogin.ts b/server/ProcDecorator/ReqLogin.ts index a8d8fe4..df30249 100644 --- a/server/ProcDecorator/ReqLogin.ts +++ b/server/ProcDecorator/ReqLogin.ts @@ -1,4 +1,4 @@ -import { ServerActionType } from "../schema/gateway/User.js"; +import type { ServerActionType } from "../schema/gateway/User.js"; import type { SessionCtx } from "./StartSession.js"; import type { ProcDecorator } from "./base.js"; @@ -6,7 +6,7 @@ export type LoginCtx = { userID: number; userName: string; userLevel: number; - allowServerAction: Set; + allowServerAction?: Set; loginDate: Date; } export const loginCtxSessionKey = 'loginCtx'; diff --git a/server/api/RootAPI/Login/LoginByID.ts b/server/api/RootAPI/Login/LoginByID.ts index 3962935..988d2ff 100644 --- a/server/api/RootAPI/Login/LoginByID.ts +++ b/server/api/RootAPI/Login/LoginByID.ts @@ -50,7 +50,7 @@ export const LoginByID = POST(LoginByIDReq)(declProcDecorat userID, userName, userLevel, - allowServerAction: {}, + allowServerAction: new Set(), loginDate: new Date(), } diff --git a/server/api/RootAPI/Login/LoginByToken.ts b/server/api/RootAPI/Login/LoginByToken.ts index 1e77732..14f4bb0 100644 --- a/server/api/RootAPI/Login/LoginByToken.ts +++ b/server/api/RootAPI/Login/LoginByToken.ts @@ -35,7 +35,7 @@ export const LoginByToken = POST(LoginByTokenReq)(declProcD userID, userName, userLevel, - allowServerAction: {}, + allowServerAction: new Set(), loginDate: new Date(), }