Skip to content

Commit

Permalink
fix: delete might have a body. (#421)
Browse files Browse the repository at this point in the history
  • Loading branch information
fantasy-is-absent committed Mar 21, 2024
1 parent 274f8d3 commit 8588209
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/oas3/Operation.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@ import { EXEGESIS_CONTROLLER, EXEGESIS_OPERATION_ID } from './extensions';
import Responses from './Responses';
import SecuritySchemes from './SecuritySchemes';

const METHODS_WITH_BODY = ['post', 'put', 'patch'];
// `delete` might have a body. See: https://developer.mozilla.org/en-US/docs/Web/HTTP/Methods/DELETE
const METHODS_WITH_BODY = ['post', 'put', 'patch', 'delete'];

function isAuthenticationFailure(result: any): result is AuthenticationFailure {
return !!(result.type === 'invalid' || result.type === 'missing');
Expand Down

0 comments on commit 8588209

Please sign in to comment.