Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Issue #1038 #1043

Merged
3 commits merged into from
Jan 1, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
14 changes: 8 additions & 6 deletions spotdl/search/provider.py
Original file line number Diff line number Diff line change
Expand Up @@ -172,14 +172,16 @@ def __query_and_simplify(searchTerm: str, apiKey: str = ytmApiKey) -> List[dict]


# Add the linkBlock

linkBlock = contents['musicResponsiveListItemRenderer'] \
['overlay'] \
['musicItemThumbnailOverlayRenderer'] \
['content'] \
['musicPlayButtonRenderer'] \
['playNavigationEndpoint']
['overlay'] \
['musicItemThumbnailOverlayRenderer'] \
['content'] \
['musicPlayButtonRenderer'].get('playNavigationEndpoint')

if linkBlock is None:
continue
s1as3r marked this conversation as resolved.
Show resolved Hide resolved

#! detailsBlock is always a list, so we just append the linkBlock to it
#! insted of carrying along all the other junk from 'musicResponsiveListItemRenderer'
result.append(linkBlock)
Expand Down