Skip to content

Commit

Permalink
Replace use of deprecated methods from Dandiset in dandi-schema p…
Browse files Browse the repository at this point in the history
…ackage
  • Loading branch information
candleindark committed Jan 26, 2024
1 parent 293161d commit 28d6fa6
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion dandiapi/api/services/version/metadata.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,4 +43,6 @@ def _normalize_version_metadata(
}
# Run the version_metadata through the pydantic model to automatically include any boilerplate
# like the access or repository fields
return PydanticDandiset.unvalidated(**version_metadata).json_dict()
return PydanticDandiset.model_construct(
**version_metadata
).model_dump(mode='json',exclude_none=True)

0 comments on commit 28d6fa6

Please sign in to comment.