summary refs log tree commit diff
path: root/api/src
diff options
context:
space:
mode:
authorFlam3rboy <34555296+Flam3rboy@users.noreply.github.com>2021-09-18 01:50:29 +0200
committerFlam3rboy <34555296+Flam3rboy@users.noreply.github.com>2021-09-18 01:50:29 +0200
commita7bf2955910772409ea9c3c6c32c0394c76f34b8 (patch)
tree3a59c1b7817039aebbde76f45327a8a71fa60600 /api/src
parent:art: use typescript plugin that converts to relative paths (diff)
downloadserver-a7bf2955910772409ea9c3c6c32c0394c76f34b8.tar.xz
:sparkles: jest automatic tests
Diffstat (limited to 'api/src')
-rw-r--r--api/src/util/route.ts5
1 files changed, 2 insertions, 3 deletions
diff --git a/api/src/util/route.ts b/api/src/util/route.ts

index 678ca64c..35ea43ba 100644 --- a/api/src/util/route.ts +++ b/api/src/util/route.ts
@@ -28,12 +28,11 @@ declare global { } } -export type RouteSchema = string; // typescript interface name -export type RouteResponse = { status?: number; body?: RouteSchema; headers?: Record<string, string> }; +export type RouteResponse = { status?: number; body?: `${string}Response`; headers?: Record<string, string> }; export interface RouteOptions { permission?: PermissionResolvable; - body?: RouteSchema; + body?: `${string}Schema`; // typescript interface name response?: RouteResponse; example?: { body?: any;