Skip to content

Commit

Permalink
increase maxlength
Browse files Browse the repository at this point in the history
  • Loading branch information
stefanseifert committed Jul 5, 2024
1 parent 8d18989 commit cdd1945
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/repository/validation.schema.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,10 @@ const loginTokenString = Joi.string()
const messageString = Joi.string()
.max(1000) // in client, only 500 allowed, but emojis are usually counted as 2

const talkModeratorNotesString = Joi.string()
.max(10000) // in client, only 5000 allowed, but emojis are usually counted as 2
.allow('')

const ratingNumber = Joi.number()
.min(1)
.max(5)
Expand All @@ -39,7 +43,7 @@ export const talkRatingObject = Joi.object({

export const talkModeratorNotesToServerObject = Joi.object({
talkId: talkIdString.required(),
text: messageString.allow('').optional()
text: talkModeratorNotesString.optional()
})

export const messageToServerObject = Joi.object({
Expand Down

0 comments on commit cdd1945

Please sign in to comment.