Fix Tumblr snippet selection

This commit is contained in:
shinigami-eyes 2020-12-26 06:53:23 +00:00
parent 3a09a7d0d4
commit b969a9fdb8
1 changed files with 1 additions and 1 deletions

View File

@ -584,7 +584,7 @@ function getSnippet(node: HTMLElement) {
if (hostname == 'youtube.com')
return getMatchingAncestorByCss(node, 'ytd-comment-renderer, ytd-video-secondary-info-renderer');
if (hostname == 'tumblr.com')
return getMatchingAncestor(node, x => (x.dataset && !!x.dataset.postId) || x.classList.contains('post'));
return getMatchingAncestor(node, x => (x.dataset && !!(x.dataset.postId || x.dataset.id)) || x.classList.contains('post'));
return null;
}