We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ff7603a commit 5115f39Copy full SHA for 5115f39
django_oapif/collections.py
@@ -163,9 +163,10 @@ def get_json_schema(
163
# from the list of required ones
164
for field_name, field_props in schema["properties"].items():
165
if field_name not in required_fields:
166
- if (t := field_props.get("AnyOf")) and len(t) == 2 and t[1] == {"type": "null"}:
167
- field_props["type"] = t[1]["type"]
168
- del field_props["AnyOf"]
+ if (t := field_props.get("anyOf")) and len(t) == 2 and t[1] == {"type": "null"}:
+ for k, v in t[0].items():
+ field_props[k] = v
169
+ del field_props["anyOf"]
170
171
if geom_field := collection.geometry_field:
172
schema["properties"][geom_field] = {
0 commit comments