mirror of
https://github.com/versia-pub/server.git
synced 2026-03-13 05:49:16 +01:00
fix(api): 🐛 Fix missing FormData acceptance for registration route
This commit is contained in:
parent
3b704b4c8c
commit
df84572148
3 changed files with 11 additions and 9 deletions
|
|
@ -1,4 +1,4 @@
|
|||
import { apiRoute, applyConfig, auth } from "@/api";
|
||||
import { apiRoute, applyConfig, auth, jsonOrForm } from "@/api";
|
||||
import { tempmailDomains } from "@/tempmail";
|
||||
import { createRoute } from "@hono/zod-openapi";
|
||||
import { and, eq, isNull } from "drizzle-orm";
|
||||
|
|
@ -42,7 +42,10 @@ const route = createRoute({
|
|||
path: "/api/v1/accounts",
|
||||
summary: "Create account",
|
||||
description: "Register a new account",
|
||||
middleware: [auth(meta.auth, meta.permissions, meta.challenge)],
|
||||
middleware: [
|
||||
auth(meta.auth, meta.permissions, meta.challenge),
|
||||
jsonOrForm(),
|
||||
],
|
||||
request: {
|
||||
body: {
|
||||
content: {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue