mirror of
https://github.com/fosrl/pangolin.git
synced 2026-02-18 10:56:38 +00:00
make username lowercase
This commit is contained in:
@@ -21,6 +21,7 @@ const bodySchema = z
|
||||
.object({
|
||||
email: z
|
||||
.string()
|
||||
.toLowerCase()
|
||||
.optional()
|
||||
.refine((data) => {
|
||||
if (data) {
|
||||
@@ -28,7 +29,7 @@ const bodySchema = z
|
||||
}
|
||||
return true;
|
||||
}),
|
||||
username: z.string().nonempty(),
|
||||
username: z.string().nonempty().toLowerCase(),
|
||||
name: z.string().optional(),
|
||||
type: z.enum(["internal", "oidc"]).optional(),
|
||||
idpId: z.number().optional(),
|
||||
|
||||
Reference in New Issue
Block a user