Skip to content

Commit

Permalink
get_playlist: fix albums on tracks
Browse files Browse the repository at this point in the history
  • Loading branch information
sigma67 committed Feb 4, 2024
1 parent 18a6f20 commit eef807f
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions ytmusicapi/parsers/playlists.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,13 +46,9 @@ def parse_playlist_items(results, menu_entries: Optional[List[List]] = None, is_

artists = parse_song_artists(data, 1)

album = parse_song_album(data, 2)
album = parse_song_album(data, 3)

views = None
if album and album["id"] is None:
# views currently only present on albums and formatting is localization-dependent -> no parsing
if (views := (get_item_text(data, 2))) is not None:
album = None
views = get_item_text(data, 2)

duration = None
if "fixedColumns" in data:
Expand Down

0 comments on commit eef807f

Please sign in to comment.