openapi-explorer 2.2.688 → 2.2.689

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -323,13 +323,11 @@ export function pathSecurityTemplate(pathSecurityOptions) {
323
323
  const andKeyTypes = [];
324
324
  Object.keys(pSecurity).forEach(pathSecurityKey => {
325
325
  const s = this.resolvedSpec.securitySchemes.find(ss => ss.apiKeyId === pathSecurityKey);
326
- if (s) {
327
- andKeyTypes.push(getTypeDisplayHeader(s));
328
- andSecurityKeys1.push({
329
- ...s,
330
- scopes: pSecurity[pathSecurityKey]
331
- });
332
- }
326
+ andKeyTypes.push(s ? getTypeDisplayHeader(s) : pathSecurityKey);
327
+ andSecurityKeys1.push({
328
+ ...s,
329
+ scopes: pSecurity[pathSecurityKey]
330
+ });
333
331
  });
334
332
  orSecurityKeys1.push({
335
333
  securityTypes: andKeyTypes.length > 1 ? `${andKeyTypes[0]} + ${andKeyTypes.length - 1} more` : andKeyTypes[0],
@@ -202,7 +202,7 @@ function duplicateExampleWithNewPropertyValues(objectExamples, propertyName, pro
202
202
  export function getExampleValuesFromSchema(schema, config = {}) {
203
203
  // Wrap the top level so that the recursive object can treat it as a normal property and we'll hit the 'object' below, otherwise we'll never create the top level.
204
204
  if (config.xml) {
205
- const xmlResult = getExampleValuesFromSchemaRecursive(schema.type === 'object' ? {
205
+ const xmlResult = getExampleValuesFromSchemaRecursive((schema === null || schema === void 0 ? void 0 : schema.type) === 'object' ? {
206
206
  properties: {
207
207
  _root: schema
208
208
  }
@@ -330,13 +330,11 @@ function pathSecurityTemplate(pathSecurityOptions) {
330
330
  const andKeyTypes = [];
331
331
  Object.keys(pSecurity).forEach(pathSecurityKey => {
332
332
  const s = this.resolvedSpec.securitySchemes.find(ss => ss.apiKeyId === pathSecurityKey);
333
- if (s) {
334
- andKeyTypes.push(getTypeDisplayHeader(s));
335
- andSecurityKeys1.push({
336
- ...s,
337
- scopes: pSecurity[pathSecurityKey]
338
- });
339
- }
333
+ andKeyTypes.push(s ? getTypeDisplayHeader(s) : pathSecurityKey);
334
+ andSecurityKeys1.push({
335
+ ...s,
336
+ scopes: pSecurity[pathSecurityKey]
337
+ });
340
338
  });
341
339
  orSecurityKeys1.push({
342
340
  securityTypes: andKeyTypes.length > 1 ? `${andKeyTypes[0]} + ${andKeyTypes.length - 1} more` : andKeyTypes[0],
@@ -211,7 +211,7 @@ function duplicateExampleWithNewPropertyValues(objectExamples, propertyName, pro
211
211
  function getExampleValuesFromSchema(schema, config = {}) {
212
212
  // Wrap the top level so that the recursive object can treat it as a normal property and we'll hit the 'object' below, otherwise we'll never create the top level.
213
213
  if (config.xml) {
214
- const xmlResult = getExampleValuesFromSchemaRecursive(schema.type === 'object' ? {
214
+ const xmlResult = getExampleValuesFromSchemaRecursive((schema === null || schema === void 0 ? void 0 : schema.type) === 'object' ? {
215
215
  properties: {
216
216
  _root: schema
217
217
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "openapi-explorer",
3
- "version": "2.2.688",
3
+ "version": "2.2.689",
4
4
  "description": "OpenAPI Explorer - API viewer with dynamically generated components, documentation, and interaction console",
5
5
  "author": "Authress Developers <developers@authress.io>",
6
6
  "type": "module",