chore: reset initial prisma/migration

This commit is contained in:
Divlo
2022-03-21 16:08:33 +01:00
parent 19b6f96ecf
commit 6575517e50
12 changed files with 243 additions and 313 deletions

View File

@ -20,7 +20,7 @@ export const userSchema = {
id,
name: Type.String({ minLength: 1, maxLength: 30 }),
email: Type.String({ minLength: 1, maxLength: 254, format: 'email' }),
password: Type.String(),
password: Type.String({ minLength: 1 }),
logo: Type.String({ minLength: 1, format: 'uri-reference' }),
status: Type.String({ minLength: 1, maxLength: 50 }),
biography: Type.String({ minLength: 1, maxLength: 160 }),

View File

@ -8,10 +8,10 @@ export const themes = [Type.Literal('light'), Type.Literal('dark')]
export const userSettingsSchema = {
id,
language: Type.Union(languages),
theme: Type.Union(themes),
isPublicEmail: Type.Boolean(),
isPublicGuilds: Type.Boolean(),
language: Type.Union(languages, { default: 'en' }),
theme: Type.Union(themes, { default: 'dark' }),
isPublicEmail: Type.Boolean({ default: false }),
isPublicGuilds: Type.Boolean({ default: false }),
createdAt: date.createdAt,
updatedAt: date.updatedAt,
userId: id