mirror of
https://github.com/tribufu/proxmox-ve-openapi
synced 2026-05-06 07:07:28 +00:00
Fixed [n] keys because they aren't actually arrays but represent net0-netn
This commit is contained in:
parent
4a0616bb00
commit
7393ce4263
2 changed files with 2095 additions and 93 deletions
|
|
@ -55,9 +55,8 @@ function buildResponseSchema(source){
|
|||
Object.keys(source.properties || {}).forEach(k => {
|
||||
if(k.endsWith('[n]')){
|
||||
const nk = k.substr(0, k.length-3)
|
||||
schema.properties[nk] = {
|
||||
type: 'array',
|
||||
items: buildResponseSchema(source.properties[k])
|
||||
for(let i=0; i<30; i++){
|
||||
schema.properties[nk+i] = buildResponseSchema(source.properties[k])
|
||||
}
|
||||
}else{
|
||||
schema.properties[k] = buildResponseSchema(source.properties[k])
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load diff
Loading…
Add table
Add a link
Reference in a new issue