ci(core): Upgrade express-openapi-validator (no-changelog) (#9022)
This commit is contained in:
committed by
GitHub
parent
76b73a27a0
commit
a45fd0dbf4
@@ -65,20 +65,17 @@ async function createApiRouter(
|
||||
operationHandlers: handlersDirectory,
|
||||
validateRequests: true,
|
||||
validateApiSpec: true,
|
||||
formats: [
|
||||
{
|
||||
name: 'email',
|
||||
formats: {
|
||||
email: {
|
||||
type: 'string',
|
||||
validate: (email: string) => validator.isEmail(email),
|
||||
},
|
||||
{
|
||||
name: 'identifier',
|
||||
identifier: {
|
||||
type: 'string',
|
||||
validate: (identifier: string) =>
|
||||
validator.isUUID(identifier) || validator.isEmail(identifier),
|
||||
},
|
||||
{
|
||||
name: 'jsonString',
|
||||
jsonString: {
|
||||
validate: (data: string) => {
|
||||
try {
|
||||
JSON.parse(data);
|
||||
@@ -88,7 +85,7 @@ async function createApiRouter(
|
||||
}
|
||||
},
|
||||
},
|
||||
],
|
||||
},
|
||||
validateSecurity: {
|
||||
handlers: {
|
||||
ApiKeyAuth: async (
|
||||
|
||||
@@ -35,7 +35,6 @@ properties:
|
||||
$ref: './workflowSettings.yml'
|
||||
staticData:
|
||||
example: { lastId: 1 }
|
||||
nullable: true
|
||||
anyOf:
|
||||
- type: string
|
||||
format: 'jsonString'
|
||||
|
||||
Reference in New Issue
Block a user