-
Notifications
You must be signed in to change notification settings - Fork 9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error using JSON editor with array of $ref objects #2659
Comments
Just noticed the same error! |
The same problem. It's real cool feature. Guys, are you going to fix it? Thanks |
One of my teammates reported this last week and wanted to show another hand that we are affected also. |
it works if maximize
But I don't know what the meaning of these lines. Anyway thanks for Swagger UI. |
Update jsoneditor from v0.7.22 to v0.7.28 (Fixes #2659)
One of my end users has reported a problem when using
type: "array"
in the schema of a request body parameter.On closer inspection, the error only appears when the
jsonEditor
is set totrue
.The error is:
Uncaught TypeError: Cannot read property 'required' of undefined
, and occurs in the following line inlib/jsoneditor.min.js
:(
s
is the undefined reference.s
is assigned a few lines above ass = this.types[t]
; and the problem seems to be thatthis.types
is an empty array -[]
)Below is a reduced YAML example that should demonstrate the issue.
jsonEditor
to false and the API renders correctlyjsonEditor
to true and the above error occursThe text was updated successfully, but these errors were encountered: