mirror of
https://github.com/hanzo-docs/docs.git
synced 2026-10-25 04:20:02 +00:00
OpenAPI: Fix minItems being ignored
This commit is contained in:
@@ -0,0 +1,5 @@
|
||||
---
|
||||
'fumadocs-openapi': patch
|
||||
---
|
||||
|
||||
Fix `minItems` being ignored
|
||||
@@ -204,6 +204,19 @@ export function Schema({
|
||||
value: range,
|
||||
});
|
||||
|
||||
range = getRange(
|
||||
'items',
|
||||
schema.minItems,
|
||||
undefined,
|
||||
schema.maxItems,
|
||||
undefined,
|
||||
);
|
||||
if (range)
|
||||
fields.push({
|
||||
key: 'Items',
|
||||
value: range,
|
||||
});
|
||||
|
||||
if (schema.enum) {
|
||||
fields.push({
|
||||
key: 'Value in',
|
||||
|
||||
Reference in New Issue
Block a user