fix
This commit is contained in:
@@ -1,7 +1,9 @@
|
||||
import { GET } from "../defs";
|
||||
import type { structure } from "../../apiStructure/sammoRootAPI";
|
||||
import type { ExtractError, ExtractQuery, ExtractResponse } from "../../apiStructure/defs";
|
||||
import { declProcDecorators } from "../ProcDecorator/base";
|
||||
import { GET } from "../defs.js";
|
||||
import type { structure } from "../../apiStructure/sammoRootAPI.js";
|
||||
import type { ExtractError, ExtractQuery, ExtractResponse } from "../../apiStructure/defs.js";
|
||||
import { declProcDecorators } from "../ProcDecorator/base.js";
|
||||
import { ReqLogin } from "../ProcDecorator/ReqLogin.js";
|
||||
import { StartSession } from "../ProcDecorator/StartSession.js";
|
||||
|
||||
type BaseAPI = typeof structure.Login.ReqNonce;
|
||||
type RType = ExtractResponse<BaseAPI>;
|
||||
@@ -11,7 +13,10 @@ const argValidator = undefined;
|
||||
|
||||
export const ReqNonce = GET<RType, EType, QType>
|
||||
(argValidator)
|
||||
(declProcDecorators([] as const))
|
||||
(() => {
|
||||
(declProcDecorators([
|
||||
StartSession,
|
||||
ReqLogin,
|
||||
] as const))
|
||||
((query, ctx) => {
|
||||
throw new Error("Method not implemented.");
|
||||
});
|
||||
@@ -1,10 +1,10 @@
|
||||
import { POST } from "../defs";
|
||||
import type { structure } from "../../apiStructure/sammoRootAPI";
|
||||
import type { ExtractError, ExtractQuery, ExtractResponse } from "../../apiStructure/defs";
|
||||
import { StartSession } from "../ProcDecorator/StartSession";
|
||||
import { POST } from "../defs.js";
|
||||
import type { structure } from "../../apiStructure/sammoRootAPI.js";
|
||||
import type { ExtractError, ExtractQuery, ExtractResponse } from "../../apiStructure/defs.js";
|
||||
import { StartSession } from "../ProcDecorator/StartSession.js";
|
||||
import { IsString } from "class-validator";
|
||||
import { delay } from "../../util/delay";
|
||||
import { declProcDecorators } from "../ProcDecorator/base";
|
||||
import { delay } from "../../util/delay.js";
|
||||
import { declProcDecorators } from "../ProcDecorator/base.js";
|
||||
|
||||
type BaseAPI = typeof structure.Login.LoginByID;
|
||||
type RType = ExtractResponse<BaseAPI>;
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
import { POST } from "../defs";
|
||||
import type { structure } from "../../apiStructure/sammoRootAPI";
|
||||
import type { ExtractError, ExtractQuery, ExtractResponse } from "../../apiStructure/defs";
|
||||
import { StartSession } from "../ProcDecorator/StartSession";
|
||||
import { POST } from "../defs.js";
|
||||
import type { structure } from "../../apiStructure/sammoRootAPI.js";
|
||||
import type { ExtractError, ExtractQuery, ExtractResponse } from "../../apiStructure/defs.js";
|
||||
import { StartSession } from "../ProcDecorator/StartSession.js";
|
||||
import { IsNumber, IsString } from "class-validator";
|
||||
import { delay } from "../../util/delay";
|
||||
import { PackChain, ParseInType, ParseOutType, declProcDecorators } from "../ProcDecorator/base";
|
||||
import { delay } from "../../util/delay.js";
|
||||
import { declProcDecorators } from "../ProcDecorator/base.js";
|
||||
type BaseAPI = typeof structure.Login.LoginByToken;
|
||||
type RType = ExtractResponse<BaseAPI>;
|
||||
type EType = ExtractError<BaseAPI>;
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
import { GET } from "../defs";
|
||||
import type { structure } from "../../apiStructure/sammoRootAPI";
|
||||
import type { ExtractError, ExtractQuery, ExtractResponse } from "../../apiStructure/defs";
|
||||
import { StartSession } from "../ProcDecorator/StartSession";
|
||||
import { declProcDecorators } from "../ProcDecorator/base";
|
||||
import { GET } from "../defs.js";
|
||||
import type { structure } from "../../apiStructure/sammoRootAPI.js";
|
||||
import type { ExtractError, ExtractQuery, ExtractResponse } from "../../apiStructure/defs.js";
|
||||
import { StartSession } from "../ProcDecorator/StartSession.js";
|
||||
import { declProcDecorators } from "../ProcDecorator/base.js";
|
||||
|
||||
type BaseAPI = typeof structure.Login.ReqNonce;
|
||||
type RType = ExtractResponse<BaseAPI>;
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
import type { structure } from "../../apiStructure/sammoRootAPI";
|
||||
import type { APINamespaceType } from "../defs";
|
||||
import { LoginByID } from "./LoginByID";
|
||||
import { LoginByToken } from "./LoginByToken";
|
||||
import { ReqNonce } from "./ReqNonce";
|
||||
import { test } from "./test";
|
||||
import type { structure } from "../../apiStructure/sammoRootAPI.js";
|
||||
import type { APINamespaceType } from "../defs.js";
|
||||
import { LoginByID } from "./LoginByID.js";
|
||||
import { LoginByToken } from "./LoginByToken.js";
|
||||
import { ReqNonce } from "./ReqNonce.js";
|
||||
import { test } from "./test.js";
|
||||
|
||||
export const Login = {
|
||||
LoginByID,
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { GET } from "../defs";
|
||||
import type { structure } from "../../apiStructure/sammoRootAPI";
|
||||
import type { ExtractError, ExtractQuery, ExtractResponse } from "../../apiStructure/defs";
|
||||
import { declProcDecorators } from "../ProcDecorator/base";
|
||||
import { GET } from "../defs.js";
|
||||
import type { structure } from "../../apiStructure/sammoRootAPI.js";
|
||||
import type { ExtractError, ExtractQuery, ExtractResponse } from "../../apiStructure/defs.js";
|
||||
import { declProcDecorators } from "../ProcDecorator/base.js";
|
||||
|
||||
type BaseAPI = typeof structure.Login.test;
|
||||
type RType = ExtractResponse<BaseAPI>;
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import type { LoginCtx } from "./ReqLogin";
|
||||
import type { SessionCtx } from "./StartSession";
|
||||
import type { ProcDecoratorGenerator } from "./base";
|
||||
import type { LoginCtx } from "./ReqLogin.js";
|
||||
import type { SessionCtx } from "./StartSession.js";
|
||||
import type { ProcDecoratorGenerator } from "./base.js";
|
||||
import type { Request, Response } from "express";
|
||||
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import type { LoginCtx } from "./ReqLogin";
|
||||
import type { SessionCtx } from "./StartSession";
|
||||
import type { ProcDecoratorGenerator } from "./base";
|
||||
import type { LoginCtx } from "./ReqLogin.js";
|
||||
import type { SessionCtx } from "./StartSession.js";
|
||||
import type { ProcDecoratorGenerator } from "./base.js";
|
||||
import type { Request, Response } from "express";
|
||||
import { delay } from "../../util/delay.js";
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import type { SessionCtx } from "./StartSession";
|
||||
import type { DecoratorResultFalse, DecoratorResultTrue, ProcDecorator, ProcDecoratorGenerator } from "./base";
|
||||
import type { SessionCtx } from "./StartSession.js";
|
||||
import type { DecoratorResultFalse, DecoratorResultTrue, ProcDecorator, ProcDecoratorGenerator } from "./base.js";
|
||||
|
||||
export type LoginCtx = {
|
||||
userID: number;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import type { Empty, ProcDecoratorGenerator } from "./base";
|
||||
import type { Empty, ProcDecoratorGenerator } from "./base.js";
|
||||
|
||||
export type SessionCtx = {
|
||||
clearSession: () => Promise<void>;
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
|
||||
import type { Request, Response } from 'express';
|
||||
import type { Callable, DefAPINamespace, DeleteAPICallT, GetAPICallT, HeadAPICallT, HttpMethod, InvalidResponse, PatchAPICallT, PostAPICallT, PutAPICallT, RawArgType, ValidResponse, recoveryMethod } from '../apiStructure/defs';
|
||||
import type { Callable, DefAPINamespace, DeleteAPICallT, GetAPICallT, HeadAPICallT, HttpMethod, InvalidResponse, PatchAPICallT, PostAPICallT, PutAPICallT, RawArgType, ValidResponse, recoveryMethod } from '../apiStructure/defs.js';
|
||||
import {
|
||||
validate,
|
||||
type ValidatorOptions,
|
||||
|
||||
+3
-3
@@ -1,6 +1,6 @@
|
||||
import type { structure } from "../apiStructure/sammoRootAPI";
|
||||
import type { APINamespaceType } from "./defs";
|
||||
import { Login } from "./Login";
|
||||
import type { structure } from "../apiStructure/sammoRootAPI.js";
|
||||
import type { APINamespaceType } from "./defs.js";
|
||||
import { Login } from "./Login/index.js";
|
||||
|
||||
export const sammoRootAPI = {
|
||||
Login,
|
||||
|
||||
Reference in New Issue
Block a user