mirror of
https://github.com/linux-odyssey/linux-odyssey.git
synced 2026-11-06 03:20:13 +08:00
9 lines
333 B
JavaScript
9 lines
333 B
JavaScript
import { check } from 'express-validator'
|
|
import { noError } from '../../middleware/validator.js'
|
|
|
|
const checkQuestId = () =>
|
|
check('quest_id').notEmpty().isString().isLowercase().isLength({ max: 64 })
|
|
|
|
export const createSessionValidator = [checkQuestId(), noError]
|
|
export const activeSessionValidator = [checkQuestId(), noError]
|