Skip to content

Commit

Permalink
fix: MetaItem.videos should allow null
Browse files Browse the repository at this point in the history
Signed-off-by: Lachezar Lechev <[email protected]>
  • Loading branch information
elpiel committed Jan 2, 2024
1 parent 3f6e890 commit 092b0df
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/types/resource/meta_item.rs
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ struct MetaItemPreviewLegacy {
#[serde(default)]
#[serde_as(deserialize_as = "DefaultOnNull")]
genres: Vec<String>,
#[serde(default)]
links: Option<Vec<Link>>,
#[serde(default)]
#[serde_as(deserialize_as = "DefaultOnNull<Vec<PickFirst<(_, Stream)>>>")]
Expand Down Expand Up @@ -199,7 +200,7 @@ pub struct MetaItem {
pub preview: MetaItemPreview,
#[serde(default)]
#[serde_as(
deserialize_as = "SortedVec<UniqueVec<Vec<_>, VideoUniqueVecAdapter>, VideoSortedVecAdapter>"
deserialize_as = "DefaultOnNull<SortedVec<UniqueVec<Vec<_>, VideoUniqueVecAdapter>, VideoSortedVecAdapter>>"
)]
pub videos: Vec<Video>,
}
Expand Down

0 comments on commit 092b0df

Please sign in to comment.