(
name: string,
security: HttpApiSecurity
)
| 537 | }) |
| 538 | |
| 539 | function processHttpApiSecurity( |
| 540 | name: string, |
| 541 | security: HttpApiSecurity |
| 542 | ) { |
| 543 | const scheme = makeSecurityScheme(security) |
| 544 | if (!Object.hasOwn(spec.components.securitySchemes, name)) { |
| 545 | InternalRecord.assignProperty(spec.components.securitySchemes, name, scheme) |
| 546 | return |
| 547 | } |
| 548 | if ( |
| 549 | !Equal.equals( |
| 550 | securitySchemeForComparison(spec.components.securitySchemes[name]), |
| 551 | securitySchemeForComparison(scheme) |
| 552 | ) |
| 553 | ) { |
| 554 | throw new globalThis.Error(`Conflicting OpenAPI security scheme: ${name}`) |
| 555 | } |
| 556 | } |
| 557 | |
| 558 | const hasBody = HttpMethod.hasBody(endpoint.method) |
| 559 | if (hasBody) { |
no test coverage detected