You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[Optional] Sponsorship to speed up the bug fix or feature request (example)
Description
When a Schema has multiple array properties with same $ref, only the first array property gets correct type. The example file works correctly using openapi: 3.0.0
type alias BarAndFoos={ arrayFooOne :ListFoo, arrayFooTwo :MaybeAnyType-- Should be `Maybe (List Foo)`, arrayFooThree :MaybeAnyType-- Should be `List Foo`}
Golang
typeBarAndFoosstruct {
ArrayFooOne []Foo`json:"arrayFooOne"`ArrayFooTwointerface{} `json:"arrayFooTwo,omitempty"`// Should be ArrayFooTwo []FooArrayFooThreeinterface{} `json:"arrayFooThree"`// Should be ArrayFooThree []Foo
}
Java
publicList<Foo> getArrayFooOne() {
returnarrayFooOne;
}
publicObjectgetArrayFooTwo() { // Should be public List<Foo>returnarrayFooTwo;
}
publicObjectgetArrayFooThree() { // Should be public List<Foo>returnarrayFooThree;
}
Bug Report Checklist
Description
When a
Schema
has multiplearray
properties with same$ref
, only the first array property gets correct type. The example file works correctly usingopenapi: 3.0.0
Relevant part from
Schema
:Elm
Golang
Java
openapi-generator version
openapi-generator-cli 7.5.0-SNAPSHOT
commit : f357be4
OpenAPI declaration file content or url
Generation Details
Elm:
Golang:
Java:
Steps to reproduce
Use the provided OpenAPI declaration file and generate code.
Related issues/PRs
Suggest a fix
The text was updated successfully, but these errors were encountered: