cyclosproject / ng-openapi-gen

An OpenAPI 3.0 codegen for Angular
MIT License
397 stars 132 forks source link

Duplicate identifier 'id' #62

Closed hadanin closed 4 years ago

hadanin commented 4 years ago

After generating models and services, when I run either "npm start" or "npm run build" I've got several errors on different lines like below:

Error in src/app/api/services/disability.service.ts:242:5 - error TS2300: Duplicate identifier 'id'. getDisabilityByIdRoute$Plain$Response(params: { id?: string; id: string; }): Observable<StrictHttpResponse<Disability>> { ...

note: I used https://editor.swagger.io/# to convert my JSON file to YAML.

Angular CLI: 8.3.19 Node: 12.7.0 OS: win32 x64 Angular: 8.2.14

luisfpg commented 4 years ago

Can you post the source of your descriptor? At least the relevant part? It seems like you have 2 parameters with the same name...

hadanin commented 4 years ago

my bad! You're are right! There are two ids in parameters.