parseArtistTopVideo static method

VideoDetailed parseArtistTopVideo(
  1. dynamic item,
  2. ArtistBasic artistBasic
)

Implementation

static VideoDetailed parseArtistTopVideo(
    dynamic item, ArtistBasic artistBasic) {
  return VideoDetailed(
    type: "VIDEO",
    videoId: traverseString(item, ["videoId"]) ?? '',
    name: traverseString(item, ["runs", "text"]) ?? '',
    artist: artistBasic,
    duration: null,
    thumbnails: traverseList(item, ["thumbnails"])
        .map((item) => ThumbnailFull.fromMap(item))
        .toList(),
  );
}