mirror of
https://github.com/versia-pub/server.git
synced 2026-03-13 05:49:16 +01:00
refactor(api): ♻️ Simplify route schema definitions
This commit is contained in:
parent
4926d6ff5d
commit
16f302c2dc
74 changed files with 175 additions and 254 deletions
|
|
@ -5,7 +5,7 @@ import { z } from "zod";
|
|||
import { InboxJobType, inboxQueue } from "~/classes/queues/inbox";
|
||||
import { ErrorSchema } from "~/types/api";
|
||||
|
||||
export const schemas = {
|
||||
const schemas = {
|
||||
param: z.object({
|
||||
uuid: z.string().uuid(),
|
||||
}),
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ import { z } from "zod";
|
|||
import { ApiError } from "~/classes/errors/api-error";
|
||||
import { ErrorSchema } from "~/types/api";
|
||||
|
||||
export const schemas = {
|
||||
const schemas = {
|
||||
param: z.object({
|
||||
uuid: z.string().uuid(),
|
||||
}),
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ import { ApiError } from "~/classes/errors/api-error";
|
|||
import { config } from "~/packages/config-manager";
|
||||
import { ErrorSchema } from "~/types/api";
|
||||
|
||||
export const schemas = {
|
||||
const schemas = {
|
||||
param: z.object({
|
||||
uuid: z.string().uuid(),
|
||||
}),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue