mirror of
https://github.com/TeamNewPipe/NewPipeExtractor.git
synced 2024-12-14 14:20:33 +05:30
Merge pull request #572 from golfinq/fixed-comments
Fixes missing comments under videos
This commit is contained in:
commit
b608587e4d
@ -46,7 +46,12 @@ public class YoutubeCommentsExtractor extends CommentsExtractor {
|
||||
|
||||
@Override
|
||||
public InfoItemsPage<CommentsInfoItem> getInitialPage() throws IOException, ExtractionException {
|
||||
final String commentsTokenInside = findValue(responseBody, "commentSectionRenderer", "}");
|
||||
final String commentsTokenInside;
|
||||
if (responseBody.contains("commentSectionRenderer")) {
|
||||
commentsTokenInside = findValue(responseBody, "commentSectionRenderer", "}");
|
||||
} else {
|
||||
commentsTokenInside = findValue(responseBody, "sectionListRenderer", "}");
|
||||
}
|
||||
final String commentsToken = findValue(commentsTokenInside, "continuation\":\"", "\"");
|
||||
return getPage(getNextPage(commentsToken));
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user