We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 99fd9bc + 0402f89 commit b39272bCopy full SHA for b39272b
src/helpers.js
@@ -27,6 +27,9 @@ export function isSwagger2(spec) {
27
28
// Strategy for determining operationId
29
export function opId(operation, pathName, method = '') {
30
+ if (!operation || typeof operation !== 'object') {
31
+ return null
32
+ }
33
const idWithoutWhitespace = (operation.operationId || '').replace(/\s/g, '')
34
if (idWithoutWhitespace.length) {
35
return escapeString(operation.operationId)
0 commit comments