( pathItem: PathItemObject, operation: OperationObject, docServers: readonly ServerInfo[], )
| 560 | const extractServers = (doc: ParsedDocument): ServerInfo[] => extractServerList(doc.servers); |
| 561 | |
| 562 | const operationServers = ( |
| 563 | pathItem: PathItemObject, |
| 564 | operation: OperationObject, |
| 565 | docServers: readonly ServerInfo[], |
| 566 | ): readonly ServerInfo[] => { |
| 567 | const operationLevel = extractServerList(operation.servers); |
| 568 | if (operationLevel.length > 0) return operationLevel; |
| 569 | const pathLevel = extractServerList(pathItem.servers); |
| 570 | if (pathLevel.length > 0) return pathLevel; |
| 571 | return docServers; |
| 572 | }; |
| 573 | |
| 574 | /** OAuth scope requirements an operation declares via `security`, with the |
| 575 | * spec's semantics preserved (OpenAPI 3.x Security Requirement Objects): |
no test coverage detected