groupsSchema: refine --> transform
This commit is contained in:
parent
a9b79f72b4
commit
607e6b1808
1 changed files with 1 additions and 1 deletions
|
@ -25,7 +25,7 @@ const groupSchema = z.object({
|
||||||
locked: z.boolean().catch(false),
|
locked: z.boolean().catch(false),
|
||||||
membership_required: z.boolean().catch(false),
|
membership_required: z.boolean().catch(false),
|
||||||
members_count: z.number().catch(0),
|
members_count: z.number().catch(0),
|
||||||
note: z.string().refine(note => note === '<p></p>' ? '' : note).catch(''),
|
note: z.string().transform(note => note === '<p></p>' ? '' : note).catch(''),
|
||||||
relationship: groupRelationshipSchema.nullable().catch(null), // Dummy field to be overwritten later
|
relationship: groupRelationshipSchema.nullable().catch(null), // Dummy field to be overwritten later
|
||||||
statuses_visibility: z.string().catch('public'),
|
statuses_visibility: z.string().catch('public'),
|
||||||
uri: z.string().catch(''),
|
uri: z.string().catch(''),
|
||||||
|
|
Loading…
Reference in a new issue