Skip to content

Commit

Permalink
fixed linting
Browse files Browse the repository at this point in the history
  • Loading branch information
Athul0491 committed Feb 23, 2024
1 parent 3de0cda commit d58a2b1
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions src/processors/OpenAPIInputProcessor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,8 @@ export class OpenAPIInputProcessor extends AbstractInputProcessor {
//Replace any '/' with '_'
const formattedResponseName = responseName.replace(/\//, '_');
this.iterateMediaType(
(response as OpenAPIV3.ResponseObject | OpenAPIV3_1.ResponseObject).content || {},
(response as OpenAPIV3.ResponseObject | OpenAPIV3_1.ResponseObject)
.content || {},
`${path}_${formattedResponseName}`,
inputModel,
options
Expand Down Expand Up @@ -209,7 +210,9 @@ export class OpenAPIInputProcessor extends AbstractInputProcessor {
}

private iterateMediaType(
mediaTypes: { [media: string]: OpenAPIV3.MediaTypeObject | OpenAPIV3_1.MediaTypeObject},
mediaTypes: {
[media: string]: OpenAPIV3.MediaTypeObject | OpenAPIV3_1.MediaTypeObject;
},
path: string,
inputModel: InputMetaModel,
options?: ProcessorOptions
Expand All @@ -219,8 +222,9 @@ export class OpenAPIInputProcessor extends AbstractInputProcessor {
if (mediaType.schema === undefined) {
continue;
}
const mediaTypeSchema =
mediaType.schema as unknown as OpenAPIV3.SchemaObject | OpenAPIV3_1.SchemaObject;
const mediaTypeSchema = mediaType.schema as unknown as
| OpenAPIV3.SchemaObject
| OpenAPIV3_1.SchemaObject;
//Replace any '/' with '_'
const formattedMediaContent = mediaContent.replace(/\//, '_');
this.includeSchema(
Expand Down

0 comments on commit d58a2b1

Please sign in to comment.