From d3bb7550d0e9ae2a20d87a5bcd2ba574c0724d65 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vasco=20Gon=C3=A7alves?= Date: Thu, 7 Mar 2024 10:58:24 +0100 Subject: [PATCH] resolve examples for shared schemas --- lib/spec/openapi/utils.js | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/spec/openapi/utils.js b/lib/spec/openapi/utils.js index 5433bbad..80740bcd 100644 --- a/lib/spec/openapi/utils.js +++ b/lib/spec/openapi/utils.js @@ -470,6 +470,7 @@ function prepareOpenapiSchemas (schemas, ref) { .reduce((res, [name, schema]) => { const _ = { ...schema } const resolved = transformDefsToComponents(ref.resolve(_, { externalSchemas: [schemas] })) + resolveSchemaExamplesRecursive(schema) // Swagger doesn't accept $id on /definitions schemas. // The $ids are needed by Ref() to check the URI so we need