Skip to content

Commit

Permalink
fixed python compatibility for song.from_dict func
Browse files Browse the repository at this point in the history
format with black
  • Loading branch information
xnetcat committed Oct 30, 2022
1 parent d9ab6a9 commit fb26ec7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion spotdl/types/song.py
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,8 @@ def from_dict(cls, data: Dict[str, Any]) -> "Song":
(
list_class
for list_class in SongList.__subclasses__()
if list(list_class.__match_args__) == list(data["song_list"].keys())
if list(list_class.__dataclass_fields__.keys())
== list(data["song_list"].keys())
)
)

Expand Down

0 comments on commit fb26ec7

Please sign in to comment.