mirror of
https://github.com/umami-software/umami.git
synced 2026-02-04 04:37:11 +01:00
/api/website/<id>: Make name and domain fields optional in POST request schema
This commit is contained in:
parent
60eaaaff60
commit
7343ee4593
1 changed files with 2 additions and 2 deletions
|
|
@ -31,8 +31,8 @@ export async function POST(
|
||||||
{ params }: { params: Promise<{ websiteId: string }> },
|
{ params }: { params: Promise<{ websiteId: string }> },
|
||||||
) {
|
) {
|
||||||
const schema = z.object({
|
const schema = z.object({
|
||||||
name: z.string(),
|
name: z.string().optional(),
|
||||||
domain: z.string(),
|
domain: z.string().optional(),
|
||||||
shareId: z.string().regex(SHARE_ID_REGEX).nullable().optional(),
|
shareId: z.string().regex(SHARE_ID_REGEX).nullable().optional(),
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue