mirror of
https://github.com/fluxerapp/fluxer
synced 2026-10-07 19:22:14 +09:00
fix(schema): keep template topics optional after trimming (#3247)
This commit is contained in:
@@ -61,8 +61,8 @@ export const TemplateChannel = z.object({
|
|||||||
topic: z
|
topic: z
|
||||||
.string()
|
.string()
|
||||||
.max(TEMPLATE_TOPIC_MAX_LENGTH)
|
.max(TEMPLATE_TOPIC_MAX_LENGTH)
|
||||||
|
.transform(clipTopic)
|
||||||
.nullish()
|
.nullish()
|
||||||
.transform((value) => (value == null ? value : clipTopic(value)))
|
|
||||||
.describe('The channel topic, shortened to the Fluxer channel topic limit'),
|
.describe('The channel topic, shortened to the Fluxer channel topic limit'),
|
||||||
position: Int32Type.describe('The position of the channel'),
|
position: Int32Type.describe('The position of the channel'),
|
||||||
parent_id: TemplateEntityId.nullish().describe('The template-local ID of the parent category'),
|
parent_id: TemplateEntityId.nullish().describe('The template-local ID of the parent category'),
|
||||||
|
|||||||
Reference in New Issue
Block a user