Skip to content

Commit

Permalink
Merge pull request #41045 from nextcloud/fix/openapi/provisioning_api…
Browse files Browse the repository at this point in the history
…/quota-fields

fix(provisioning_api): Fix quota fields in OpenAPI
  • Loading branch information
nickvergessen authored Oct 23, 2023
2 parents 6114364 + d019392 commit 06b3580
Show file tree
Hide file tree
Showing 2 changed files with 44 additions and 12 deletions.
8 changes: 4 additions & 4 deletions apps/provisioning_api/lib/ResponseDefinitions.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,11 @@

/**
* @psalm-type ProvisioningApiUserDetailsQuota = array{
* free?: float,
* free?: float|int,
* quota?: float|int|string,
* relative?: float,
* total?: float,
* used?: float,
* relative?: float|int,
* total?: float|int,
* used?: float|int,
* }
*
* @psalm-type ProvisioningApiUserDetails = array{
Expand Down
48 changes: 40 additions & 8 deletions apps/provisioning_api/openapi.json
Original file line number Diff line number Diff line change
Expand Up @@ -507,8 +507,16 @@
"type": "object",
"properties": {
"free": {
"type": "number",
"format": "float"
"oneOf": [
{
"type": "number",
"format": "float"
},
{
"type": "integer",
"format": "int64"
}
]
},
"quota": {
"oneOf": [
Expand All @@ -526,16 +534,40 @@
]
},
"relative": {
"type": "number",
"format": "float"
"oneOf": [
{
"type": "number",
"format": "float"
},
{
"type": "integer",
"format": "int64"
}
]
},
"total": {
"type": "number",
"format": "float"
"oneOf": [
{
"type": "number",
"format": "float"
},
{
"type": "integer",
"format": "int64"
}
]
},
"used": {
"type": "number",
"format": "float"
"oneOf": [
{
"type": "number",
"format": "float"
},
{
"type": "integer",
"format": "int64"
}
]
}
}
}
Expand Down

0 comments on commit 06b3580

Please sign in to comment.