File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -124,14 +124,16 @@ export function normalizeSwagger(parsedSpec) {
124124 Object . keys ( map ) . forEach ( ( op ) => {
125125 if ( map [ op ] . length > 1 ) {
126126 map [ op ] . forEach ( ( o , i ) => {
127+ o . __originalOperationId = o . __originalOperationId || o . operationId
127128 o . operationId = `${ op } ${ i + 1 } `
128129 } )
129130 } else {
130131 // Ensure we always add the normalized operation ID if one already exists ( potentially different, given that we normalize our IDs)
131132 // ... _back_ to the spec. Otherwise, they might not line up
132133 if ( typeof operation . operationId !== 'undefined' ) {
133- operation . __originalOperationId = operation . operationId
134- operation . operationId = op
134+ let obj = map [ op ] [ 0 ]
135+ obj . __originalOperationId = obj . __originalOperationId || operation . operationId
136+ obj . operationId = op
135137 }
136138 }
137139
You can’t perform that action at this time.
0 commit comments